diff options
Diffstat (limited to 'usr.bin/patch/common.h')
-rw-r--r-- | usr.bin/patch/common.h | 47 |
1 files changed, 3 insertions, 44 deletions
diff --git a/usr.bin/patch/common.h b/usr.bin/patch/common.h index ff7b3934ab0..7da6a168f2f 100644 --- a/usr.bin/patch/common.h +++ b/usr.bin/patch/common.h @@ -1,27 +1,11 @@ -/* $OpenBSD: common.h,v 1.12 2003/04/08 01:54:56 deraadt Exp $ */ +/* $OpenBSD: common.h,v 1.13 2003/07/18 02:00:09 deraadt Exp $ */ #define DEBUGGING -#define VOIDUSED 7 #include "config.h" /* shut lint up about the following when return value ignored */ -#define Signal (void)signal -#define Unlink (void)unlink -#define Lseek (void)lseek -#define Fseek (void)fseek -#define Fstat (void)fstat -#define Pclose (void)pclose -#define Close (void)close -#define Fclose (void)fclose -#define Fflush (void)fflush -#define Snprintf (void)snprintf - -/* NeXT declares malloc and realloc incompatibly from us in some of - these files. Temporarily redefine them to prevent errors. */ -#define malloc system_malloc -#define realloc system_realloc #include <stdio.h> #include <string.h> #include <assert.h> @@ -34,9 +18,9 @@ #include <signal.h> #include <stdlib.h> #include <unistd.h> +#include <stdarg.h> #include <libgen.h> -#undef malloc -#undef realloc +#include <errno.h> /* constants */ @@ -63,13 +47,8 @@ #define CHECKOUT "co -l %s" #define RCSDIFF "rcsdiff %s > /dev/null" -#ifdef FLEXFILENAMES #define ORIGEXT ".orig" #define REJEXT ".rej" -#else -#define ORIGEXT "~" -#define REJEXT "#" -#endif /* handy definitions */ @@ -157,26 +136,6 @@ EXT char end_defined[128]; /* #endif xyzzy */ EXT char *revision INIT(Nullch); /* prerequisite revision, if any */ -#include <errno.h> -#ifndef errno -extern int errno; -#endif - -FILE *popen(); -char *malloc(); -char *realloc(); -long atol(); -char *getenv(); -char *strrchr(); -int mkstemp(); -#if 0 /* This can cause a prototype conflict. */ -#ifdef CHARSPRINTF -char *snprintf(); -#else -int snprintf(); -#endif -#endif - #if !defined(S_ISDIR) && defined(S_IFDIR) #define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR) #endif |