GTA SA CLEO CRASH FIX CODE
![gta sa cleo crash fix gta sa cleo crash fix](https://fely.online/wp-content/uploads/2019/06/GTA_SA_3_LITE_BY_JEJAKSHARE.ME_-e1611492506455.png)
If the script needs it, they can use global paths. Was an idea to allow scripts changing the current directory to an arbitrary We only need to adjust the file manipulation opcodes (open_file,Ĭreate_directory, file_exists, directory_exists). If they use a relative path then the dir the script last gave for chdir is Just avoid chdir by operating on any paths each script is set to use, so
![gta sa cleo crash fix gta sa cleo crash fix](https://www.gtagaming.com/images/1723/carfire.jpg)
Regarding a possible solution, if you'd ask me I'm all for the Deji's The current directory anywhere else but that ship has sailed already. I don't think scripts should be able to set This is why initially chdir only accepted 0 and 1 to chooseīetween the two directories. The script should only operate within the game directory using relative The goal was to get access to the User Files directory, as in normal case The global state and lead to subtle bugs and race conditions. I think adding chdir command in user scripts was a mistake as it mutates Unfortunately the same behavior had been implemented in CLEO for III/VC so we would need to fix it there too. I would not care about any other opcode unless you can provide a clear use case when it's absolutely needed. As being said there never was an idea to allow scripts changing the current directory to an arbitrary path. We only need to adjust the file manipulation opcodes (open_file, create_directory, file_exists, directory_exists). Just avoid chdir by operating on any paths each script is set to use, so if they use a relative path then the dir the script last gave for chdir is prepended, or the default path is used. Regarding a possible solution, if you'd ask me I'm all for the Deji's proposal: I don't think scripts should be able to set the current directory anywhere else but that ship has sailed already. This is why initially chdir only accepted 0 and 1 to choose between the two directories. Ultimately the goal was to get access to the User Files directory, as in normal case the script should only operate within the game directory using relative paths.
![gta sa cleo crash fix gta sa cleo crash fix](https://bf2war.ru/uploads/posts/2016-02/1456445658_19550852.jpg)
I think adding chdir command in user scripts was a mistake as it mutates the global state and lead to subtle bugs and race conditions. That fix should go in the direction of not using chdir to read files in User Files from another thread.įYI I've sent you a CLEO.asi patched with the second fix.
GTA SA CLEO CRASH FIX MODS
Considering CAEStreamThread behavior is so subtle and non-deterministic, probably breaking so many other mods with their authors not even noticing, a fix on that should probably be good. Thus I ask you if you could please give context on the introduction of this feature in 4.3. Chdir is prone to race conditions, using it in any form should be avoided, not encouraged.