diff options
author | Dmitry V. Levin <ldv@altlinux.org> | 2010-09-06 22:08:24 +0000 |
---|---|---|
committer | Dmitry V. Levin <ldv@altlinux.org> | 2010-09-07 00:59:18 +0000 |
commit | 30145dda9d7ff70df1d5ad750a183572c73e8963 (patch) | |
tree | ae931a871df38fddd20dd8111f83112c5f494e6b /stream.c | |
parent | cbdd1900a16016343c172db09fc48a83e7fa22ac (diff) | |
download | strace-30145dda9d7ff70df1d5ad750a183572c73e8963.tar.gz strace-30145dda9d7ff70df1d5ad750a183572c73e8963.tar.bz2 strace-30145dda9d7ff70df1d5ad750a183572c73e8963.tar.xz |
Fix const-correctness issues uncovered by gcc -Wwrite-strings
* defs.h (struct xlat): Add const qualifier to the field of
type "char *".
(set_sortby, qualify, printnum, printnum_int): Add const qualifier to
arguments of type "char *".
* count.c (set_sortby): Add const qualifier to the argument and
automatic variable of type "char *".
* desc.c (decode_select): Add const qualifier to automatic variables of
type "char *".
* ioctlsort.c (struct ioctlent): Add const qualifier to fields of
type "char *".
(main): Add const qualifier to argv.
* process.c (printargv): Add const qualifier to the argument and
automatic variable of type "char *".
(printargc) Add const qualifier to argument of type "char *".
* signal.c (sprintsigmask, parse_sigset_t): Add const qualifier to
arguments of type "char *".
* strace.c (progname): Add const qualifier.
(detach): Add const qualifier to automatic variable of type "char *".
* stream.c (struct strbuf): Add const qualifier to the field of
type "char *".
* syscall.c (struct qual_options): Add const qualifier to fields of
type "char *".
(qual_syscall, qual_fault, qual_desc, lookup_class): Add const qualifier
to arguments of type "char *".
(qual_signal): Add const qualifier to the argument of type "char *",
avoid modification of constant argument.
(qualify): Likewise.
* util.c (printflags): Add const qualifier to automatic variable of
type "char *".
(printnum, printnum_int): Add const qualifier to arguments of
type "char *".
Diffstat (limited to 'stream.c')
-rw-r--r-- | stream.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -57,7 +57,7 @@ struct strbuf { int maxlen; /* no. of bytes in buffer */ int len; /* no. of bytes returned */ - char *buf; /* pointer to data */ + const char *buf; /* pointer to data */ }; #define MORECTL 1 #define MOREDATA 2 |