RtsFlags.c: Const correct fixes
authorErik de Castro Lopo <erikd@mega-nerd.com>
Sat, 28 May 2016 21:26:39 +0000 (07:26 +1000)
committerErik de Castro Lopo <erikd@mega-nerd.com>
Sat, 28 May 2016 21:26:40 +0000 (07:26 +1000)
Test Plan: validate

Reviewers: hvr, austin, simonmar, bgamari

Reviewed By: bgamari

Subscribers: thomie

Differential Revision: https://phabricator.haskell.org/D2275

rts/RtsFlags.c

index 31a2c8b..1ec5db0 100644 (file)
@@ -1609,8 +1609,8 @@ static rtsBool read_heap_profiling_flag(const char *arg)
     case 'b':
         if (arg[2] != '\0' && arg[3] != '\0') {
             {
-                char *left  = strchr(arg, '{');
-                char *right = strrchr(arg, '}');
+                const char *left  = strchr(arg, '{');
+                const char *right = strrchr(arg, '}');
 
                 // curly braces are optional, for
                 // backwards compat.