From 05279ca074900b17889d5a5d059099914481d326 Mon Sep 17 00:00:00 2001 From: Joel Brobecker Date: Tue, 27 Feb 2007 22:57:42 +0000 Subject: * buildsym.c (record_producer): Do nothing if no producer is provided. --- gdb/ChangeLog | 4 ++++ gdb/buildsym.c | 5 +++++ 2 files changed, 9 insertions(+) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index ef74a7f..754ecc8 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,7 @@ +2007-02-26 Joel Brobecker + + * buildsym.c (record_producer): Do nothing if no producer is provided. + 2007-02-28 Nick Roberts * varobj.c (varobj_update): Remove unused local. Use gdb_assert diff --git a/gdb/buildsym.c b/gdb/buildsym.c index ae0750a..94800bd 100644 --- a/gdb/buildsym.c +++ b/gdb/buildsym.c @@ -1139,6 +1139,11 @@ record_debugformat (char *format) void record_producer (const char *producer) { + /* The producer is not always provided in the debugging info. + Do nothing if PRODUCER is NULL. */ + if (producer == NULL) + return; + current_subfile->producer = savestring (producer, strlen (producer)); } -- cgit v1.1