constify solib_add
authorTom Tromey <tromey@redhat.com>
Mon, 21 Jul 2014 23:05:16 +0000 (17:05 -0600)
committerTom Tromey <tromey@redhat.com>
Thu, 24 Jul 2014 17:30:02 +0000 (11:30 -0600)
This constifies the "pattern" argument to solib_add.

2014-07-24  Tom Tromey  <tromey@redhat.com>

* solib.c (solib_add): Make "pattern" const.
* solib.h (solib_add): Update.

gdb/ChangeLog
gdb/solib.c
gdb/solib.h

index 944c245..608bfb8 100644 (file)
@@ -1,5 +1,10 @@
 2014-07-24  Tom Tromey  <tromey@redhat.com>
 
+       * solib.c (solib_add): Make "pattern" const.
+       * solib.h (solib_add): Update.
+
+2014-07-24  Tom Tromey  <tromey@redhat.com>
+
        * remote.c (remote_serial_open, print_packet, putpkt)
        (putpkt_binary): Constify.
        * remote.h (putpkt): Update.
index e0afca0..c8f141f 100644 (file)
@@ -900,7 +900,7 @@ libpthread_solib_p (struct so_list *so)
    FROM_TTY and TARGET are as described for update_solib_list, above.  */
 
 void
-solib_add (char *pattern, int from_tty,
+solib_add (const char *pattern, int from_tty,
           struct target_ops *target, int readsyms)
 {
   struct so_list *gdb;
index 29fe8f7..4a7f56e 100644 (file)
@@ -33,7 +33,7 @@ extern void clear_solib (void);
 
 /* Called to add symbols from a shared library to gdb's symbol table.  */
 
-extern void solib_add (char *, int, struct target_ops *, int);
+extern void solib_add (const char *, int, struct target_ops *, int);
 extern int solib_read_symbols (struct so_list *, int);
 
 /* Function to be called when the inferior starts up, to discover the