changeset 29211:649920d8a5bf

maint: merge stable to default.
author Markus Mützel <markus.muetzel@gmx.de>
date Mon, 21 Dec 2020 11:53:10 +0100
parents 403a9f626ba2 (current diff) e8819aa30715 (diff)
children cf059093ffbc
files liboctave/system/file-stat.cc
diffstat 1 files changed, 2 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/liboctave/system/file-stat.cc	Sun Dec 20 18:48:41 2020 +0100
+++ b/liboctave/system/file-stat.cc	Mon Dec 21 11:53:10 2020 +0100
@@ -38,6 +38,7 @@
 
 #if defined (OCTAVE_USE_WINDOWS_API)
 #  include "lo-regexp.h"
+#  include "oct-env.h"
 #endif
 
 namespace octave
@@ -194,12 +195,7 @@
           std::string full_file_name = sys::file_ops::tilde_expand (file_name);
 
 #if defined (OCTAVE_USE_WINDOWS_API)
-          std::string canon_file_name
-            = sys::canonicalize_file_name (full_file_name);
-
-          // Might have failed for files with non-ASCII characters in name
-          if (! canon_file_name.empty ())
-            full_file_name = canon_file_name;
+          full_file_name = sys::env::make_absolute (full_file_name);
 
           // Remove trailing slashes
           while (full_file_name.length () > 1