# HG changeset patch # User jwe # Date 1114578499 0 # Node ID bc8d6ebb6ee1e2c5b478a423d22bf85577e08d32 # Parent 4c8a2e4e0717bf20f2f48eff03be083f2a01cfa5 [project @ 2005-04-27 05:08:19 by jwe] diff -r 4c8a2e4e0717 -r bc8d6ebb6ee1 src/ChangeLog --- a/src/ChangeLog Tue Apr 26 19:24:47 2005 +0000 +++ b/src/ChangeLog Wed Apr 27 05:08:19 2005 +0000 @@ -1,3 +1,7 @@ +2005-04-27 John W. Eaton + + * parse.y: (safe_fclose): Delete comment list to avoid memory leak. + 2005-04-26 John W. Eaton * mkbuiltins (VAR_FILES): Expect $(VAR_FILES) to have .df suffix. diff -r 4c8a2e4e0717 -r bc8d6ebb6ee1 src/comment-list.cc --- a/src/comment-list.cc Tue Apr 26 19:24:47 2005 +0000 +++ b/src/comment-list.cc Wed Apr 27 05:08:19 2005 +0000 @@ -58,7 +58,6 @@ instance->do_append (s, t); } - octave_comment_list * octave_comment_buffer::get_comment (void) { diff -r 4c8a2e4e0717 -r bc8d6ebb6ee1 src/parse.y --- a/src/parse.y Tue Apr 26 19:24:47 2005 +0000 +++ b/src/parse.y Wed Apr 27 05:08:19 2005 +0000 @@ -2919,7 +2919,9 @@ // statement, possibly from the command line or another file, which // can be quite confusing). - octave_comment_buffer::get_comment (); + octave_comment_list *tc = octave_comment_buffer::get_comment (); + + delete tc; if (f) fclose (static_cast (f));