# HG changeset patch # User John W. Eaton # Date 1314133891 14400 # Node ID 07dc4839c05fb8a89db229a8049af0c36a2bc352 # Parent 00235a6446da84e7b2f1f1a89ae1250183b09a1b properly save and restore command history file name in history command (bug #32524) * oct-hist.cc (do_history): Protect command_history file. diff -r 00235a6446da -r 07dc4839c05f src/oct-hist.cc --- a/src/oct-hist.cc Tue Aug 23 17:08:51 2011 -0400 +++ b/src/oct-hist.cc Tue Aug 23 17:11:31 2011 -0400 @@ -133,6 +133,10 @@ { int numbered_output = 1; + unwind_protect frame; + + frame.add_fcn (command_history::set_file, command_history::file ()); + int i; for (i = 1; i < argc; i++) {