aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2001-07-31 02:02:45 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2001-07-31 02:02:45 +0000
commitc4c194f100475e04806c891ac942542b88c15554 (patch)
tree63574b8d826177a77c7ce9fff0d5b236696c6670
parent267a8f82bf9a05d179fb2c3e156d42b12433d6c0 (diff)
downloadpostgresql-c4c194f100475e04806c891ac942542b88c15554.tar.gz
postgresql-c4c194f100475e04806c891ac942542b88c15554.zip
Fix unportable coding for FRONTEND case.
-rw-r--r--src/backend/lib/dllist.c19
1 files changed, 9 insertions, 10 deletions
diff --git a/src/backend/lib/dllist.c b/src/backend/lib/dllist.c
index 08e6ddb364f..7a41dd295ca 100644
--- a/src/backend/lib/dllist.c
+++ b/src/backend/lib/dllist.c
@@ -9,7 +9,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/lib/dllist.c,v 1.23 2001/06/02 15:16:55 wieck Exp $
+ * $Header: /cvsroot/pgsql/src/backend/lib/dllist.c,v 1.24 2001/07/31 02:02:45 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -17,7 +17,6 @@
/* can be used in frontend or backend */
#ifdef FRONTEND
#include "postgres_fe.h"
-#include <sysexits.h>
/* No assert checks in frontend ... */
#define Assert(condition)
#else
@@ -34,14 +33,14 @@ DLNewList(void)
l = (Dllist *) malloc(sizeof(Dllist));
if (l == NULL)
-#ifdef FRONTEND
{
- fprintf(stderr, "Memory exhausted in DLNewList");
- exit(EX_UNAVAILABLE);
- }
+#ifdef FRONTEND
+ fprintf(stderr, "Memory exhausted in DLNewList\n");
+ exit(1);
#else
elog(ERROR, "Memory exhausted in DLNewList");
#endif
+ }
l->dll_head = 0;
l->dll_tail = 0;
@@ -77,14 +76,14 @@ DLNewElem(void *val)
e = (Dlelem *) malloc(sizeof(Dlelem));
if (e == NULL)
-#ifdef FRONTEND
{
- fprintf(stderr, "Memory exhausted in DLNewList");
- exit(EX_UNAVAILABLE);
- }
+#ifdef FRONTEND
+ fprintf(stderr, "Memory exhausted in DLNewElem\n");
+ exit(1);
#else
elog(ERROR, "Memory exhausted in DLNewElem");
#endif
+ }
e->dle_next = 0;
e->dle_prev = 0;
e->dle_val = val;