Mercurial > octave
changeset 29634:1b945016d837
load-path: Add ids to warnings for load path update failures (bug #48865).
* libinterp/corefcn/load-path.cc (load_path::update,
load_path::dir_info::update): Add ids to warnings.
author | Robert Jenssen <robertjenssen@ozemail.com.au> |
---|---|
date | Wed, 05 May 2021 12:15:56 +1000 |
parents | a548bab9eafa |
children | 955832ec3af1 |
files | libinterp/corefcn/load-path.cc |
diffstat | 1 files changed, 7 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/libinterp/corefcn/load-path.cc Fri May 07 21:05:56 2021 -0400 +++ b/libinterp/corefcn/load-path.cc Wed May 05 12:15:56 2021 +1000 @@ -408,8 +408,10 @@ bool ok = di.update (); if (! ok) - warning ("load-path: update failed for '%s', removing from path", - di.dir_name.c_str ()); + warning_with_id + ("Octave:load-path:update-failed", + "load-path: update failed for '%s', removing from path", + di.dir_name.c_str ()); else add (di, true, "", true); } @@ -1332,7 +1334,9 @@ if (! fs) { std::string msg = fs.error (); - warning ("load_path: %s: %s", dir_name.c_str (), msg.c_str ()); + warning_with_id ("Octave:load-path:dir-info:update-failed", + "load_path: %s: %s", dir_name.c_str (), msg.c_str ()); + return false; }