Sfoglia il codice sorgente

Modified to include the appropriate header file rather than (badly)
prototyping syscalls itself.

dtrg 18 anni fa
parent
commit
dc5d08b2a3
4 ha cambiato i file con 2 aggiunte e 14 eliminazioni
  1. 0 12
      util/ack/ack.h
  2. 1 0
      util/ack/main.c
  3. 1 0
      util/ack/run.c
  4. 0 2
      util/opt/lookup.c

+ 0 - 12
util/ack/ack.h

@@ -64,18 +64,6 @@ typedef struct {
 /* Return values of setpath() */
 enum f_path { F_OK, F_NOMATCH, F_NOPATH } ;
 
-/* Library routines */
-
-extern char *strchr();
-extern char *strrchr();
-extern char *strcpy();
-extern char *strcat();
-extern int  getpid();
-extern int  unlink();
-extern int  close();
-extern int  open();
-extern int  creat();
-
 /* Own routines */
 enum f_path getpath();
 enum f_path scan_end();

+ 1 - 0
util/ack/main.c

@@ -6,6 +6,7 @@
 
 #include <stdlib.h>
 #include <stdio.h>
+#include <string.h>
 #include "ack.h"
 #include "list.h"
 #include "trans.h"

+ 1 - 0
util/ack/run.c

@@ -5,6 +5,7 @@
  */
 
 #include <stdlib.h>
+#include <string.h>
 #include "ack.h"
 #include "list.h"
 #include "trans.h"

+ 0 - 2
util/opt/lookup.c

@@ -18,8 +18,6 @@ static char rcsid[] = "$Id$";
  * Author: Hans van Staveren
  */
 
-extern char *strncpy();
-
 unsigned hash(string) char *string; {
 	register char *p;
 	register unsigned i,sum;