I am looking for any info. (I know some C++ with win32 and C#)
The idea is to help a program with missing files load. In the end I wanted to see if I could have my program launch a simple c++ executable that requires a dll which prints "hello world" to standard output. The quirk would be that the dll is not present in the folder. The c++ program instead of crashing is suspended and the main program has to request the dll from some source. When the dll is loaded, the printing process is resumed and continues running.
Example of execution.
MainProcess => start("a.exe"); a.exe => LoadLibrary("test.dll"); OS responds with "file does not exist". MainProcess catches said exception.
MainProcess suspends a.exe like in this example.
MainProcess finds dll. MainProcess dispatches the exception. MainProcess tells gets a.exe to attempt loading again.
Are there cases where this kind of thing would not work? Can a parent capture exceptions meant for children?
How would one do that?
Also is it possible to tell exactly which files a process will need before running it?