Sfoglia il codice sorgente

try to fix https://github.com/blueloveTH/pocketpy/issues/43

blueloveTH 2 anni fa
parent
commit
d25e27df4a
1 ha cambiato i file con 1 aggiunte e 0 eliminazioni
  1. 1 0
      src/main.cpp

+ 1 - 0
src/main.cpp

@@ -63,6 +63,7 @@ int main(int argc, char** argv){
         if(argv_1 == "-h" || argv_1 == "--help") goto __HELP;
 
         std::filesystem::path filepath(argv[1]);
+        filepath = std::filesystem::absolute(filepath);
         if(!std::filesystem::exists(filepath)){
             std::cerr << "File not found: " << argv_1 << std::endl;
             return 1;