Author | Message | Time |
---|---|---|
aton | hi, i am developing bnet stuff for linux. bncsutil works fine, thanks to whoever works on it! for those who are interested: yesterday i added some threading functions to my code and linked against the pthread library. after that kd_create failed all the time, i did some research and saw that kd_lock_decoders() fails, i.e. this code: [code] int err = 0; pthread_cond_t cond = PTHREAD_COND_INITIALIZER; struct timespec wait_time = {0, MUTEX_TIMEOUT_MS * 1000}; err = pthread_cond_timedwait(&cond, &mutex, &wait_time); [/code] pthread_cond_timedwait returns nonzero which causes the bug. i am now using fork() instead of threads, though its a bit inconvenient. greetings, aton | July 16, 2008, 1:28 PM |
K | I suggest you call perror if the call returns non-zero to get an idea why it's failing. (or if you cant print from that context, use strerror(errno) to get the error string). | July 16, 2008, 8:56 PM |