fixdep: constify strrcmp arguments
authorNicolas Iooss <nicolas.iooss_linux@m4x.org>
Wed, 18 Nov 2015 18:07:15 +0000 (19:07 +0100)
committerMichal Marek <mmarek@suse.com>
Mon, 7 Dec 2015 11:42:55 +0000 (12:42 +0100)
strrcmp only performs read access to the memory addressed by its
arguments so make them const pointers.

Signed-off-by: Nicolas Iooss <nicolas.iooss_linux@m4x.org>
Signed-off-by: Michal Marek <mmarek@suse.com>
scripts/basic/fixdep.c

index c68fd61..5b327c6 100644 (file)
@@ -251,7 +251,7 @@ static void parse_config_file(const char *map, size_t len)
 }
 
 /* test is s ends in sub */
-static int strrcmp(char *s, char *sub)
+static int strrcmp(const char *s, const char *sub)
 {
        int slen = strlen(s);
        int sublen = strlen(sub);