]> granicus.if.org Git - strace/commitdiff
tests: fix clang "duplicate 'const' declaration specifier" warnings
authorDmitry V. Levin <ldv@altlinux.org>
Tue, 12 Jan 2016 05:02:08 +0000 (05:02 +0000)
committerDmitry V. Levin <ldv@altlinux.org>
Tue, 12 Jan 2016 05:06:10 +0000 (05:06 +0000)
* tests/ksysent.c (pstr_t): Remove second const specifier.
* tests/mmsg.c (main): Remove second const specifier from one[], two[],
and three[].

tests/ksysent.c
tests/mmsg.c

index 1d099177ff6dd7caf74f5e0861006dfc6feaed0c..66b4ffb4115b0ec8b0635c73c7d0049e14ca5c4f 100644 (file)
@@ -45,7 +45,7 @@ static const struct_sysent syscallent[] = {
 #include "syscallent.h"
 };
 
-typedef const char const *pstr_t;
+typedef const char *pstr_t;
 static const pstr_t ksyslist[] = {
 #include "ksysent.h"
 };
index 0c9c7115864efbd9b73fb5273a9998d9d4a0e7fd..ba7fc3e2f908399c5000698b28af6bda10394b4d 100644 (file)
@@ -90,9 +90,9 @@ main(void)
        assert(R == sv[0]);
        assert(W == sv[1]);
 
-       static const char const one[] = "one";
-       static const char const two[] = "two";
-       static const char const three[] = "three";
+       static const char one[] = "one";
+       static const char two[] = "two";
+       static const char three[] = "three";
        void *copy_one = tail_memdup(one, sizeof(one) - 1);
        void *copy_two = tail_memdup(two, sizeof(two) - 1);
        void *copy_three = tail_memdup(three, sizeof(three) - 1);