$NetBSD: patch-ak,v 1.1 2008/02/23 03:45:12 hfath Exp $ --- explode/trbatch.c.orig 1994-11-30 23:09:10.000000000 +0100 +++ explode/trbatch.c @@ -2,6 +2,7 @@ * transmit batch file management (exploder version) */ #include +#include #include #include "fixerrno.h" #include @@ -21,6 +22,13 @@ /* # of hash buckets for batch file names */ #endif /* HASHFILSZ */ +/* Renamed because of collision with libcnews/trbatcomm.c */ +STATIC statust trbfrclose(); + +/* Removed from include/trbatch.h - only used locally */ +STATIC struct batchfile * bfisopen(); +STATIC struct batchfile * bfincache(); + static HASHTABLE *nmbftbl; /* name -> batchfile mapping */ /* @@ -42,7 +50,7 @@ register char *name; bf->bf_str = fopenclex(name, "a"); /* silent try */ if (bf->bf_str == NULL && errno == EMFILE) { /* try to free up a descriptor */ - if (bfrclose() != ST_OKAY) + if (trbfrclose() != ST_OKAY) return NULL; errno = 0; warning( @@ -86,7 +94,7 @@ char *name; /* * returns a batchfile, never NULL, corresponding to name. */ -struct batchfile * +STATIC struct batchfile * bfincache(name) char *name; { @@ -161,7 +169,7 @@ char *hook; } STATIC statust -bfrclose() /* close an arbitrary batchfile */ +trbfrclose() /* close an arbitrary batchfile */ { struct closehook closehook; register struct closehook *chp = &closehook; @@ -173,7 +181,7 @@ bfrclose() /* close an arbitrary batc hashwalk(nmbftbl, closefirst, (char *)chp); if (!chp->closedone) { errno = 0; - warning("bfrclose couldn't find an open descriptor to close", + warning("tr_bfrclose couldn't find an open descriptor to close", ""); /* canthappen */ } return chp->status; @@ -196,6 +204,7 @@ char *hook; error("can't delete hash key `%s'", key); /* canthappen */ } +#if 0 /* This exists already in trbatcomm.c */ STATIC statust bfrealclose() /* close all open batch files */ { @@ -207,7 +216,7 @@ bfrealclose() /* close all open batch hashwalk(nmbftbl, closeone, (char *)chp); return chp->status; } - +#endif /* * search the batchfile cache for "name"; return the corresponding