diff options
author | Ryan Long <ryan.long@oarcorp.com> | 2021-09-30 11:48:08 -0400 |
---|---|---|
committer | Joel Sherrill <joel@rtems.org> | 2021-10-07 09:25:22 -0500 |
commit | 83b3d58c4d10cad13cdf9130936ad245c332b741 (patch) | |
tree | c8715dcf0412c391f8bfbad898bee4f6cc8cad53 /trace/record | |
parent | record-client.c: Ignore return value from visit() (diff) | |
download | rtems-tools-83b3d58c4d10cad13cdf9130936ad245c332b741.tar.bz2 |
record-main-lttng.cc: Change size of empty string
CID 1503017: Out-of-bounds access in CopyThreadName().
Change size of kEmptyThreadName from THREAD_API_COUNT to
THREAD_NAME_SIZE.
Closes #4519
Diffstat (limited to 'trace/record')
-rw-r--r-- | trace/record/record-main-lttng.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/trace/record/record-main-lttng.cc b/trace/record/record-main-lttng.cc index 7cfa48c..faa762d 100644 --- a/trace/record/record-main-lttng.cc +++ b/trace/record/record-main-lttng.cc @@ -59,7 +59,7 @@ #define BITS_PER_CHAR 8 #define COMPACT_HEADER_ID 31 -static const uint8_t kEmptyThreadName[THREAD_API_COUNT] = ""; +static const uint8_t kEmptyThreadName[THREAD_NAME_SIZE] = ""; static const uint8_t kUUID[] = {0x6a, 0x77, 0x15, 0xd0, 0xb5, 0x02, 0x4c, 0x65, 0x86, 0x78, 0x67, 0x77, 0xac, 0x7f, 0x75, 0x5a}; |