Race condition when using together with mods that bind internal folders to the sdcard
It has been brought to my attention that SDRemount doesn't properly work together with SD-Card folder mounting mods, i.e. any kind of software that presents a folder stored on the SD Card as if it was present in the internal storage, for example to move the actual data of the fixed WhatsApp folder to the SD Card while preserving access to it for the WhatsApp application which will always look for it in the internal storage.
This is caused due to the fact that SDRemount never starts on its own but always reacts to Androids Broadcast notifiying it of a newly mounted SD Card. This can lead to a race condition where the execution of SD Remount is deferred while apps that might be unable to handle write errors already try to write to the SD Card.
I don't have any ideas how to easily fix this and especially no ideas how to properly prevent race conditions without hooking into the system in some way. Because of this, i will not try to fix is issue myself. However, if anyone is able to provide a working solution for merging i am looking forward to accept it. Otherwise, you can always feel free to fork the project and release an improved version of it, especially if you are willing to put more effort into maintaining it than me.