aboutsummaryrefslogtreecommitdiff
path: root/gdb
diff options
context:
space:
mode:
authorAleksandar Ristovski <aristovski@qnx.com>2011-08-26 17:58:57 +0000
committerAleksandar Ristovski <aristovski@qnx.com>2011-08-26 17:58:57 +0000
commitedb2aadf8b9b8b968917fad4727f039f0e10f7fb (patch)
treece0a0bf3eee43e20c0283e5c76ecd5a2a9a118e9 /gdb
parent7cf80422688b442803f70265465668fae16e2f38 (diff)
downloadgdb-edb2aadf8b9b8b968917fad4727f039f0e10f7fb.zip
gdb-edb2aadf8b9b8b968917fad4727f039f0e10f7fb.tar.gz
gdb-edb2aadf8b9b8b968917fad4727f039f0e10f7fb.tar.bz2
* linespec.c (symtab_from_filename): Check for the end of string.
Diffstat (limited to 'gdb')
-rw-r--r--gdb/ChangeLog4
-rw-r--r--gdb/linespec.c2
2 files changed, 6 insertions, 0 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 3a5b491..5179af7 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,7 @@
+2011-08-26 Aleksandar Ristovski <aristovski@qnx.com>
+
+ * linespec.c (symtab_from_filename): Check for the end of string.
+
2011-08-26 Marc Khouzam <marc.khouzam@ericsson.com>
PR mi/11912
diff --git a/gdb/linespec.c b/gdb/linespec.c
index b96c79f..37ec368 100644
--- a/gdb/linespec.c
+++ b/gdb/linespec.c
@@ -1835,6 +1835,8 @@ symtab_from_filename (char **argptr, char *p, int is_quote_enclosed)
}
/* Discard the file name from the arg. */
+ if (*p1 == '\0')
+ return file_symtab;
p = p1 + 1;
while (*p == ' ' || *p == '\t')
p++;