Mercurial > hg > octave-avbm
changeset 3870:a9baa340ea51
[project @ 2002-02-22 15:42:44 by jwe]
author | jwe |
---|---|
date | Fri, 22 Feb 2002 15:42:44 +0000 |
parents | 63aa2e20e638 |
children | b747adc02286 |
files | src/ChangeLog src/pager.cc |
diffstat | 2 files changed, 13 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,9 @@ +2002-02-22 John W. Eaton <jwe@bevo.che.wisc.edu> + + * pager.cc (octave_pager_buf::sync): Set pointer to beginning + of buffer after calling flush_currnt_contents_to_diary. + (octave_diary_buf::sync): Call eback only once. + 2002-01-03 John W. Eaton <jwe@bevo.che.wisc.edu> * lex.l (.): Remove test for EOF since it is already handled
--- a/src/pager.cc +++ b/src/pager.cc @@ -239,9 +239,9 @@ { do_sync (buf, len, bypass_pager); - seekoff (0, std::ios::beg); + flush_current_contents_to_diary (); - flush_current_contents_to_diary (); + seekoff (0, std::ios::beg); } } @@ -257,7 +257,7 @@ octave_diary.write (buf, len); - diary_skip = 0; + diary_skip = 0; } void @@ -271,10 +271,12 @@ { if (write_to_diary_file && external_diary_file) { - int len = pptr () - eback (); + char *buf = eback (); + + int len = pptr () - buf; if (len > 0) - external_diary_file.write (eback (), len); + external_diary_file.write (buf, len); } seekoff (0, std::ios::beg);