]> arthur.barton.de Git - netatalk.git/blobdiff - etc/papd/file.c
replaced all #include <sys/syslog.h> with #include <syslog.h>
[netatalk.git] / etc / papd / file.c
index 50a6986168ad6a57177b29138d0efb7776644dd6..77a919ae02e910fe89484ed215840ea41517a768 100644 (file)
@@ -1,13 +1,15 @@
 /*
+ * $Id: file.c,v 1.8 2002-01-03 17:49:39 sibaz Exp $
+ *
  * Copyright (c) 1990,1994 Regents of The University of Michigan.
  * All Rights Reserved.  See COPYRIGHT.
  */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
-#endif
+#endif /* HAVE_CONFIG_H */
 
-#include <sys/syslog.h>
+#include <syslog.h>
 #include <sys/param.h>
 #include <stdio.h>
 #include <stdlib.h>
@@ -15,7 +17,7 @@
 
 #include "file.h"
 
-markline( pf, start, linelength, crlflength )
+int markline( pf, start, linelength, crlflength )
     char               **start;
     int                        *linelength, *crlflength;
     struct papfile     *pf;
@@ -52,12 +54,13 @@ markline( pf, start, linelength, crlflength )
        (*crlflength)++;
     }
 
-    return *linelength;
+    /* success, return 1 */
+    return( 1 );
 }
 
-morespace( pf, data, len )
+void morespace( pf, data, len )
     struct papfile     *pf;
-    char               *data;
+    const char         *data;
     int                        len;
 {
     char               *nbuf;
@@ -90,22 +93,22 @@ morespace( pf, data, len )
 }
 
 
-append(pf, data, len)
+void append(pf, data, len)
     struct papfile     *pf;
-    char               *data;
+    const char         *data;
     int                        len;
 {
     if ((pf->pf_data + pf->pf_datalen + len) >
        (pf->pf_buf + pf->pf_bufsize)) {
                morespace(pf, data, len);
     } else {
-       bcopy(data, pf->pf_data + pf->pf_datalen, len);
+       memcpy(pf->pf_data + pf->pf_datalen, data, len);
        pf->pf_datalen += len;
     }
 }
 
 
-spoolerror( out, str )
+void spoolerror( out, str )
     struct papfile     *out;
     char               *str;
 {