Hi! > POSIX doesn't state that if mmap() is given only PROT_WRITE, then > that memory region will have read access too. It's an implementation > issue of the platform. > > On a platform which don't imply read access when only PROT_WRITE is given, > such a situation happens: > 1) a child process decrements the semaphore with sem_wait(sem) > 2) then tries to dereference create_cnt via (*create_cnt)++. This > will result in a SIGSEGV, and the child will be terminated. > > Therefore the semaphore will be left in a "decremented" state and this > test case will hang. > > To overcome this problem we should explicitly pass PROT_READ to mmap().
Pushed, thanks. -- Cyril Hrubis [email protected] ------------------------------------------------------------------------------ Put Bad Developers to Shame Dominate Development with Jenkins Continuous Integration Continuously Automate Build, Test & Deployment Start a new project now. Try Jenkins in the cloud. http://p.sf.net/sfu/13600_Cloudbees _______________________________________________ Ltp-list mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/ltp-list
