aboutsummaryrefslogtreecommitdiff
path: root/gdb/symmisc.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/symmisc.c')
-rw-r--r--gdb/symmisc.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/gdb/symmisc.c b/gdb/symmisc.c
index 5dcb886..cb631cb 100644
--- a/gdb/symmisc.c
+++ b/gdb/symmisc.c
@@ -397,6 +397,8 @@ print_symtabs (filename)
if (filename == 0)
error_no_arg ("file to write symbol data in");
outfile = fopen (filename, "w");
+ if (outfile == 0)
+ perror_with_name (filename);
cleanups = make_cleanup (fclose, outfile);
immediate_quit++;