summaryrefslogtreecommitdiff
blob: 4644542204bae49f8bfc1d75b583ae5c05871e4d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
diff -aurp checkpassword-0.90-orig/alloc.c checkpassword-0.90/alloc.c
--- checkpassword-0.90-orig/alloc.c	2019-10-18 18:32:45.888000000 +0200
+++ checkpassword-0.90/alloc.c	2019-10-18 18:39:41.820000000 +0200
@@ -1,7 +1,6 @@
+#include <stdlib.h>
 #include "alloc.h"
 #include "error.h"
-extern char *malloc();
-extern void free();
 
 #define ALIGNMENT 16 /* XXX: assuming that this alignment is enough */
 #define SPACE 2048 /* must be multiple of ALIGNMENT */
diff -aurp checkpassword-0.90-orig/checkpassword.c checkpassword-0.90/checkpassword.c
--- checkpassword-0.90-orig/checkpassword.c	2019-10-18 18:32:45.888000000 +0200
+++ checkpassword-0.90/checkpassword.c	2019-10-18 18:42:00.352000000 +0200
@@ -1,3 +1,4 @@
+#include <string.h>
 #include <unistd.h>
 
 #include "error.h"
@@ -23,6 +24,7 @@ static struct userpw *upw;
 static char up[513];
 static int uplen;
 
+int
 main(int argc,char **argv)
 {
   char *login;
diff -aurp checkpassword-0.90-orig/chkshsgr.c checkpassword-0.90/chkshsgr.c
--- checkpassword-0.90-orig/chkshsgr.c	2019-10-18 18:32:45.888000000 +0200
+++ checkpassword-0.90/chkshsgr.c	2019-10-18 18:38:29.436000000 +0200
@@ -1,5 +1,8 @@
+#include <grp.h>
+#include <unistd.h>
 #include "exit.h"
 
+int
 main()
 {
   short x[4];
diff -aurp checkpassword-0.90-orig/install.c checkpassword-0.90/install.c
--- checkpassword-0.90-orig/install.c	2019-10-18 18:32:45.888000000 +0200
+++ checkpassword-0.90/install.c	2019-10-18 18:43:52.968000000 +0200
@@ -1,3 +1,6 @@
+#include <sys/stat.h>
+#include <sys/types.h>
+#include <unistd.h>
 #include "buffer.h"
 #include "strerr.h"
 #include "error.h"
@@ -137,6 +140,7 @@ int mode;
     strerr_die6sys(111,FATAL,"unable to chmod .../",subdir,"/",file,": ");
 }
 
+int
 main()
 {
   fdsourcedir = open_read(".");
diff -aurp checkpassword-0.90-orig/instcheck.c checkpassword-0.90/instcheck.c
--- checkpassword-0.90-orig/instcheck.c	2019-10-18 18:32:45.888000000 +0200
+++ checkpassword-0.90/instcheck.c	2019-10-18 18:42:42.428000000 +0200
@@ -101,6 +101,7 @@ int mode;
   perm("",home,"/",file,S_IFREG,uid,gid,mode);
 }
 
+int
 main()
 {
   hier();
diff -aurp checkpassword-0.90-orig/pathexec_run.c checkpassword-0.90/pathexec_run.c
--- checkpassword-0.90-orig/pathexec_run.c	2019-10-18 18:32:45.888000000 +0200
+++ checkpassword-0.90/pathexec_run.c	2019-10-18 18:40:42.944000000 +0200
@@ -1,3 +1,4 @@
+#include <unistd.h>
 #include "error.h"
 #include "stralloc.h"
 #include "str.h"
diff -aurp checkpassword-0.90-orig/prot.c checkpassword-0.90/prot.c
--- checkpassword-0.90-orig/prot.c	2019-10-18 18:32:45.888000000 +0200
+++ checkpassword-0.90/prot.c	2019-10-18 18:37:28.668000000 +0200
@@ -1,3 +1,5 @@
+#include <grp.h>
+#include <unistd.h>
 #include "hasshsgr.h"
 #include "prot.h"
 
diff -aurp checkpassword-0.90-orig/readwrite.h checkpassword-0.90/readwrite.h
--- checkpassword-0.90-orig/readwrite.h	2019-10-18 18:32:45.888000000 +0200
+++ checkpassword-0.90/readwrite.h	2019-10-18 18:33:59.732000000 +0200
@@ -1,7 +1,6 @@
 #ifndef READWRITE_H
 #define READWRITE_H
 
-extern int read();
-extern int write();
+#include <unistd.h>
 
 #endif