2003-05-02 David Carlton <carlton@bactrian.org>
authorDavid Carlton <carlton@bactrian.org>
Fri, 2 May 2003 17:00:57 +0000 (17:00 +0000)
committerDavid Carlton <carlton@bactrian.org>
Fri, 2 May 2003 17:00:57 +0000 (17:00 +0000)
* objfiles.c (allocate_objfile): For anonymous objfiles, allocate
the name with mstrsave.

gdb/ChangeLog
gdb/objfiles.c

index 1826ec7..8914375 100644 (file)
@@ -1,3 +1,8 @@
+2003-05-02  David Carlton  <carlton@bactrian.org>
+
+       * objfiles.c (allocate_objfile): For anonymous objfiles, allocate
+       the name with mstrsave.
+
 2003-05-02  Elena Zannoni  <ezannoni@redhat.com>
 
        * charset.c (GDB_DEFAULT_TARGET_CHARSET,
index 32a57fa..59e03b9 100644 (file)
@@ -325,7 +325,7 @@ allocate_objfile (bfd *abfd, int flags)
     }
   else
     {
-      objfile->name = "<<anonymous objfile>>";
+      objfile->name = mstrsave (objfile->md, "<<anonymous objfile>>");
     }
 
   /* Initialize the section indexes for this objfile, so that we can