Procházet zdrojové kódy

Merge pull request #98921 from RandomShaper/win_many_files

Raise the number of file handles on Windows
Rémi Verschelde před 10 měsíci
rodič
revize
c2f19e98bc
1 změnil soubory, kde provedl 3 přidání a 0 odebrání
  1. 3 0
      drivers/windows/file_access_windows.cpp

+ 3 - 0
drivers/windows/file_access_windows.cpp

@@ -525,6 +525,9 @@ void FileAccessWindows::initialize() {
 		invalid_files.insert(reserved_files[reserved_file_index]);
 		reserved_file_index++;
 	}
+
+	_setmaxstdio(8192);
+	print_verbose(vformat("Maximum number of file handles: %d", _getmaxstdio()));
 }
 
 void FileAccessWindows::finalize() {