[Mono-dev] Here's a patch for /dev/shm/mono.pid's piling up on Linux

cpMon page.cal at gmail.com
Wed Mar 3 08:54:51 EST 2010

Here's a patch you should consider for mono-2.6.1. Specifically, I noticed
that /dev/shm/mono.pid files were piling up and not being cleaned up as they
should have been. mono-mmap.c tries to get rid of stale ones with a kill but
they don't check for ENOMEM return which causes the cleanup to fail.
Additionally, every other time I tried to start mono, it would just quit.

Here's the patch:

< if (curpid != pid && kill (pid, SIGCONT) == -1 && (errno == ESRCH || errno
== ENOMEM) ) {
> if (curpid != pid && kill (pid, SIGCONT) == -1 && errno == ESRCH) {

This has been tested on various 2.6 Linux boxes successfully.

Cal Page 
View this message in context: http://n4.nabble.com/Here-s-a-patch-for-dev-shm-mono-pid-s-piling-up-on-Linux-tp1576561p1576561.html
Sent from the Mono - Dev mailing list archive at Nabble.com.

More information about the Mono-devel-list mailing list