--- libaitsched/src/aitsched.c 2012/08/23 02:33:12 1.16 +++ libaitsched/src/aitsched.c 2012/08/31 13:00:41 1.16.2.1 @@ -3,7 +3,7 @@ * by Michael Pounov * * $Author: misho $ -* $Id: aitsched.c,v 1.16 2012/08/23 02:33:12 misho Exp $ +* $Id: aitsched.c,v 1.16.2.1 2012/08/31 13:00:41 misho Exp $ * ************************************************************************** The ELWIX and AITNET software is distributed under the following @@ -151,7 +151,7 @@ schedInit(void ** __restrict data, size_t datlen) #ifdef HAVE_LIBPTHREAD for (i = 0; i < taskMAX; i++) - if (pthread_mutex_init(&root->root_mtx[i], NULL)) { + if ((errno = pthread_mutex_init(&root->root_mtx[i], NULL))) { LOGERR; while (i) pthread_mutex_destroy(&root->root_mtx[--i]);