Current server behavior is to create the swtfb.01 message queue statically and never clean it. I think it would be useful to add a invariant that the message queue exists if and only if the server is running and accepting requests. This way, external scripts could simply check for the message queue existence to test whether the server has started (see toltec-dev/toltec#455).
This would require two changes:
Add an atexit hook to clean up the message queue.
Only instantiate the message queue after checking that offsets are defined for the current system version.
I'm not sure about the atexit hook, could it cause open programs to point to a different piece of memory? as long as rm2fb doesn't create shm if the address isn't found, I think it's ok
Current server behavior is to create the
swtfb.01
message queue statically and never clean it. I think it would be useful to add a invariant that the message queue exists if and only if the server is running and accepting requests. This way, external scripts could simply check for the message queue existence to test whether the server has started (see toltec-dev/toltec#455).This would require two changes: