Branch: Tag:

2003-04-01

2003-04-01 19:41:13 by Martin Stjernholm <mast@lysator.liu.se>

Better checking of error return codes from various thread functions. Added
-dT to enable error checking mutexes in the thread library (--with-rtldebug
is _not_ required).

Rev: man/pike.1:1.17
Rev: src/acconfig.h:1.123
Rev: src/aclocal.m4:1.68
Rev: src/configure.in:1.713
Rev: src/main.c:1.171
Rev: src/main.h:1.22
Rev: src/pike_threadlib.h:1.39
Rev: src/threads.c:1.214

2:   || This file is part of Pike. For copyright information see COPYRIGHT.   || Pike is distributed under GPL, LGPL and MPL. See the file COPYING   || for more information. - || $Id: main.c,v 1.170 2003/03/30 17:15:09 mast Exp $ + || $Id: main.c,v 1.171 2003/04/01 19:41:13 mast Exp $   */      #include "global.h" - RCSID("$Id: main.c,v 1.170 2003/03/30 17:15:09 mast Exp $"); + RCSID("$Id: main.c,v 1.171 2003/04/01 19:41:13 mast Exp $");   #include "fdlib.h"   #include "backend.h"   #include "module.h"
444:    p++;    goto more_d_flags;    +  case 'T': +  debug_options |= ERRORCHECK_MUTEXES; +  p++; +  goto more_d_flags; +     default:    d_flag += (p[0] == 'd');    p++;
518:    }    }    + #ifndef PIKE_MUTEX_ERRORCHECK +  if (debug_options & ERRORCHECK_MUTEXES) +  fputs ("Warning: -dT (error checking mutexes) not supported on this system.\n", +  stderr); + #endif +  if (d_flag) debug_options |= ERRORCHECK_MUTEXES; +    #if !defined(RLIMIT_NOFILE) && defined(RLIMIT_OFILE)   #define RLIMIT_NOFILE RLIMIT_OFILE   #endif