Mercurial > hg > octave-lojdl
changeset 13987:2c0765c14e4f
eliminate unused error message buffer
* error.cc (error_message_buffer): Delete static variable. Messages
were written to this std::ostringstream object, but the contents
were never used.
(verror): Delete code that initialized and wrote to
error_message_buffer.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Sun, 04 Dec 2011 03:35:25 -0500 |
parents | 6be49527e4cf |
children | 7ab497513c1a |
files | src/error.cc |
diffstat | 1 files changed, 1 insertions(+), 13 deletions(-) [+] |
line wrap: on
line diff
--- a/src/error.cc +++ b/src/error.cc @@ -119,9 +119,6 @@ // TRUE means warning messages are turned off. bool discard_warning_messages = false; -// The message buffer. -static std::ostringstream *error_message_buffer = 0; - void reset_error_handler (void) { @@ -263,16 +260,7 @@ Vlast_error_stack = initialize_last_error_stack (); } - if (buffer_error_messages) - { - if (error_message_buffer) - msg_string = "error: " + msg_string; - else - error_message_buffer = new std::ostringstream (); - - *error_message_buffer << msg_string; - } - else + if (! buffer_error_messages) { octave_diary << msg_string; os << msg_string;