projects
/
xen.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4b77027
)
tools/xenmon: xenbaked: Mark const the field text in stat_map_t
author
Julien Grall
<jgrall@amazon.com>
Tue, 18 May 2021 13:51:48 +0000
(14:51 +0100)
committer
Julien Grall
<jgrall@amazon.com>
Tue, 18 May 2021 13:54:05 +0000
(14:54 +0100)
The field text in stat_map_t will point to string literals. So mark it
as const to allow the compiler to catch any modified of the string.
Signed-off-by: Julien Grall <jgrall@amazon.com>
Reviewed-by: Anthony PERARD <anthony.perard@citrix.com>
Acked-by: Wei Liu <wl@xen.org>
tools/xenmon/xenbaked.c
patch
|
blob
|
history
diff --git
a/tools/xenmon/xenbaked.c
b/tools/xenmon/xenbaked.c
index d3f940a26bb27599e4c81e20e90526c05573c91f..1ed34334c8247ce326db33874b27f0d6c74378d4 100644
(file)
--- a/
tools/xenmon/xenbaked.c
+++ b/
tools/xenmon/xenbaked.c
@@
-182,7
+182,7
@@
typedef struct
{
int event_count;
int event_id;
- char *text;
+ c
onst c
har *text;
} stat_map_t;
stat_map_t stat_map[] = {