Browse Source

Update io.cpp

blueloveTH 1 year ago
parent
commit
1b53c51cdc
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/io.cpp

+ 1 - 1
src/io.cpp

@@ -177,7 +177,7 @@ void add_module_os(VM* vm){
         try{
         try{
             di = std::filesystem::directory_iterator(path);
             di = std::filesystem::directory_iterator(path);
         }catch(std::filesystem::filesystem_error& e){
         }catch(std::filesystem::filesystem_error& e){
-            vm->IOError(Str(e.what()).lstrip());
+            vm->IOError(path.string());
         }
         }
         List ret;
         List ret;
         for(auto& p: di) ret.push_back(VAR(p.path().filename().string()));
         for(auto& p: di) ret.push_back(VAR(p.path().filename().string()));