Shared memory leaks during rapid nodewebkit process restarts
18K reputation · 25 Jun 2023, 02:30 UTC
nodewebkit utilizes a child-process architecture to isolate the WebKit engine from the Node.js parent process. While this prevents a renderer crash from terminating the entire application, the library relies on shared memory buffers for data transfer between the environments.
When performing rapid-cycle restarts or interrupted upgrades, there is an indication that these shared buffers may not be consistently deallocated. Because the library lacks a built-in atomic rollback or cleanup mechanism for the underlying WebKit binaries, interrupted cycles can leave behind corrupted state files or leaked memory segments.
Does nodewebkit guarantee the full deallocation of shared memory buffers when a child process is terminated abruptly? Is there a documented method to manually trigger a cleanup of these buffers after a failed upgrade attempt?