diff options
author | Jim Kingdon <jkingdon@engr.sgi.com> | 1994-05-17 20:13:50 +0000 |
---|---|---|
committer | Jim Kingdon <jkingdon@engr.sgi.com> | 1994-05-17 20:13:50 +0000 |
commit | 9c036bd836f66747ccd35f6a21a2758f0f2cb8fc (patch) | |
tree | 70899574fb9676d917fe7ce6b6a24f3ffca34ab5 /gdb/utils.c | |
parent | ee8b83460016b61902117b463dfdd6d0323ce3ac (diff) | |
download | gdb-9c036bd836f66747ccd35f6a21a2758f0f2cb8fc.zip gdb-9c036bd836f66747ccd35f6a21a2758f0f2cb8fc.tar.gz gdb-9c036bd836f66747ccd35f6a21a2758f0f2cb8fc.tar.bz2 |
* utils.c (vfprintf_maybe_filtered, vfprintf_unfiltered): Call
fputs_unfiltered and exit directly, rather than fatal. The latter
calls vfprintf_unfiltered!
* gdbtypes.h, gdbtypes.c (can_dereference): New function.
* value.h, printcmd.c (print_value_flags): Move from here...
* annotate.c: ...to here, and make it use can_dereference.
Diffstat (limited to 'gdb/utils.c')
-rw-r--r-- | gdb/utils.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/gdb/utils.c b/gdb/utils.c index 1956984..de02160 100644 --- a/gdb/utils.c +++ b/gdb/utils.c @@ -1389,7 +1389,10 @@ vfprintf_maybe_filtered (stream, format, args, filter) vasprintf (&linebuffer, format, args); if (linebuffer == NULL) - fatal ("virtual memory exhausted."); + { + fputs_unfiltered ("\ngdb: virtual memory exhausted.\n", gdb_stderr); + exit (1); + } old_cleanups = make_cleanup (free, linebuffer); fputs_maybe_filtered (linebuffer, stream, filter); do_cleanups (old_cleanups); @@ -1416,7 +1419,10 @@ vfprintf_unfiltered (stream, format, args) vasprintf (&linebuffer, format, args); if (linebuffer == NULL) - fatal ("virtual memory exhausted."); + { + fputs_unfiltered ("\ngdb: virtual memory exhausted.\n", gdb_stderr); + exit (1); + } old_cleanups = make_cleanup (free, linebuffer); fputs_unfiltered (linebuffer, stream); do_cleanups (old_cleanups); |