constify xcoffread.c
authorPedro Alves <palves@redhat.com>
Mon, 9 Mar 2015 11:58:20 +0000 (11:58 +0000)
committerYao Qi <yao.qi@linaro.org>
Fri, 20 Mar 2015 17:39:13 +0000 (17:39 +0000)
/home/pedro/gdb/mygit/src/gdb/xcoffread.c: In function ‘void scan_xcoff_symtab(objfile*)’:
/home/pedro/gdb/mygit/src/gdb/xcoffread.c:2644:33: error: invalid conversion from ‘const char*’ to ‘char*’ [-fpermissive]
      p = strchr (namestring, ':');
                                 ^
gdb:

2015-03-20  Pedro Alves  <palves@redhat.com>

* xcoffread.c (scan_xcoff_symtab): Make "p" and "q" const.

gdb/ChangeLog
gdb/xcoffread.c

index b71739e8156cfb536dec2a16d0b49884769e7c26..c1d19a829aa294cf41af3977bb348994ca8cf89c 100644 (file)
@@ -1,3 +1,7 @@
+2015-03-20  Pedro Alves  <palves@redhat.com>
+
+       * xcoffread.c (scan_xcoff_symtab): Make "p" and "q" const.
+
 2015-03-20  Pedro Alves  <palves@redhat.com>
 
        * remote-m32r-sdi.c (m32r_open): Make "port_str" const.
index 3cb6eda305389db9593616a87c15b246fb536990..9571ac8f554b8295f7b7282ee298b8ffa5b55bd3 100644 (file)
@@ -2636,7 +2636,7 @@ scan_xcoff_symtab (struct objfile *objfile)
        case C_DECL:
        case C_STSYM:
          {
-           char *p;
+           const char *p;
 
            swap_sym (&symbol, &main_aux[0], &namestring, &sraw_symbol,
                      &ssymnum, objfile);
@@ -2763,7 +2763,7 @@ scan_xcoff_symtab (struct objfile *objfile)
                       Accept either.  */
                    while (*p && *p != ';' && *p != ',')
                      {
-                       char *q;
+                       const char *q;
 
                        /* Check for and handle cretinous dbx symbol name
                           continuation!  */
This page took 0.038399 seconds and 4 git commands to generate.