Mercurial > hg > octave-terminal
changeset 11843:d1b8260dbc76 release-3-0-x
fix problems from transplant 7552
author | Jaroslav Hajek <highegg@gmail.com> |
---|---|
date | Fri, 19 Sep 2008 12:30:30 +0200 |
parents | 0b9c56b6bf0e |
children | 28b0618cf67c |
files | src/ChangeLog src/load-path.cc src/utils.cc |
diffstat | 3 files changed, 11 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2008-09-19 Jaroslav Hajek <highegg@gmail.com> + + * load-path.cc: Fix errors from earlier transplant changeset. + * utils.cc: Likewise. + 2008-09-10 John W. Eaton <jwe@octave.org> * octave.cc (octave_main): Make all command-line arguments
--- a/src/load-path.cc +++ b/src/load-path.cc @@ -798,7 +798,7 @@ { std::string retval; - if (dir.find_first_of (file_ops::dir_sep_chars ()) != std::string::npos + if (dir.find_first_of (file_ops::dir_sep_chars) != std::string::npos && (octave_env::absolute_pathname (dir) || octave_env::rooted_relative_pathname (dir))) { @@ -817,7 +817,7 @@ size_t dname_len = dname.length (); - if (dname.substr (dname_len - 1) == file_ops::dir_sep_str ()) + if (dname.substr (dname_len - 1) == file_ops::dir_sep_str) dname = dname.substr (0, dname_len - 1); size_t dir_len = dir.length ();
--- a/src/utils.cc +++ b/src/utils.cc @@ -746,6 +746,10 @@ error ("errno: expecting integer argument"); } } + else if (nargin == 0) + retval = octave_errno::get (); + else + print_usage (); return retval; } @@ -768,10 +772,6 @@ if (fs.exists ()) retval = octave_env::make_absolute (tcontents, octave_env::getcwd ()); } - else if (nargin == 0) - retval = octave_errno::get (); - else - print_usage (); return retval; }