summaryrefslogtreecommitdiff
path: root/apt-pkg/contrib/error.cc
diff options
context:
space:
mode:
authorArch Librarian <arch@canonical.com>2004-09-20 16:54:31 +0000
committerArch Librarian <arch@canonical.com>2004-09-20 16:54:31 +0000
commitafd9aaf3f1751dde9ddb55dcdf3782a6aaeb4e97 (patch)
treed3ca9761aca902ddfb73c363ecca1ef7cf201985 /apt-pkg/contrib/error.cc
parent35584d03d9edd468abb10a617861404a5204df8b (diff)
Made pthread optional
Author: jgg Date: 1999-08-05 05:55:45 GMT Made pthread optional
Diffstat (limited to 'apt-pkg/contrib/error.cc')
-rw-r--r--apt-pkg/contrib/error.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/apt-pkg/contrib/error.cc b/apt-pkg/contrib/error.cc
index 8ae2686de..8db8bcc3c 100644
--- a/apt-pkg/contrib/error.cc
+++ b/apt-pkg/contrib/error.cc
@@ -1,6 +1,6 @@
// -*- mode: cpp; mode: fold -*-
// Description /*{{{*/
-// $Id: error.cc,v 1.6 1999/01/18 06:20:07 jgg Exp $
+// $Id: error.cc,v 1.7 1999/08/05 05:55:45 jgg Exp $
/* ######################################################################
Global Erorr Class - Global error mechanism
@@ -26,6 +26,7 @@
#include <stdarg.h>
#include <unistd.h>
+#include "config.h"
/*}}}*/
// Global Error Object /*{{{*/
@@ -33,8 +34,9 @@
is compiled to be thread safe otherwise a non-safe version is used. A
Per-Thread error object is maintained in much the same manner as libc
manages errno */
-#if _POSIX_THREADS == 1
+#if _POSIX_THREADS == 1 && defined(HAVE_PTHREAD)
#include <pthread.h>
+ #error PTHREAD
static pthread_key_t ErrorKey;
static void ErrorDestroy(void *Obj) {delete (GlobalError *)Obj;};