That is not a good fix. This should not be returning an error at all, since this is just a nested request for the semaphore. There's still something wrong going on with the recursive semaphores.
Rick On Tue, Jul 6, 2021 at 6:46 AM Thomas Kahr <tho...@vaime.at> wrote: > Hi all, > > below is an update on the mutex test. > > It works perfectly. The problem was in the code it seems. According to the > POSIX standard pthread_mutex_trylock should return errorcode 16 (EBUSY) if > the mutex is already locked. But the expectation value in the mutex test is > given with EDEADLK (Errorcode 35) as showed in my mail from yesterday. So > after I changed the expectation value to EBUSY everything works as hoped. > 16 is expected and returned. > > Best regards > Thomas > > > On 7/5/21 9:25 PM, Rick McGuire wrote: > > And so many other things will fail if that line is removed. > > Rick > > On Mon, Jul 5, 2021 at 3:18 PM Thomas Kahr <tho...@vaime.at> wrote: > >> Additional Info to the mutex test: >> >> Without the line: >> >> expect( pthread_mutex_trylock( &lock ), EDEADLK ); >> >> The program runs fine and I get an "OK". So everything works except this >> one line. >> >> Best regards >> >> Thomas >> >> >> On 7/5/21 6:34 PM, Erich Steinböck wrote: >> >> problems getting the configuration for the semaphores to work correctly >>> >> There really aren't a lot of configuration options any more. I just >> recently cleaned up the SysSempahore code with revision 12259. >> And I now believe that we cannot run at all without both >> pthread_mutexattr_settype and PTHREAD_MUTEX_RECURSIVE so I might as well >> remove that option too (all of our platforms that we currently run builds >> on have support for those.) >> >> Thomas, are you at revision 12259 or later? If not can you please update? >> >> The last time you reported the CMake status of the various pthread >> functionality, you showed some "failed" >> -- Looking for pthread.h >> -- Looking for pthread.h - found >> -- Looking for pthread_mutexattr_settype >> -- Looking for pthread_mutexattr_settype - not found >> -- Looking for pthread_mutex_timedlock >> -- Looking for pthread_mutex_timedlock - not found >> -- Performing Test HAVE_PTHREAD_MUTEX_ERRORCHECK >> >> *-- Performing Test HAVE_PTHREAD_MUTEX_ERRORCHECK - Failed *-- >> Performing Test HAVE_PTHREAD_MUTEX_RECURSIVE >> -- Performing Test HAVE_PTHREAD_MUTEX_RECURSIVE - Failed >> What's the current status? >> >> To test the actual mutex functionality on Android, can you compile and >> run this test? >> >> https://android.googlesource.com/platform/system/extras/+/froyo/tests/bionic/libc/bionic/test_mutex.c >> Please also test whether " #define __USE_UNIX98 1" is required to >> successfully compile/run. >> >> >> _______________________________________________ >> Oorexx-devel mailing >> listOorexx-devel@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/oorexx-devel >> >> >> _______________________________________________ >> Oorexx-devel mailing list >> Oorexx-devel@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/oorexx-devel >> > > > _______________________________________________ > Oorexx-devel mailing > listOorexx-devel@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/oorexx-devel > > > _______________________________________________ > Oorexx-devel mailing list > Oorexx-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/oorexx-devel >
_______________________________________________ Oorexx-devel mailing list Oorexx-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/oorexx-devel