summaryrefslogtreecommitdiff
blob: 1f2a39f29168552b29087aac212452a0a5c6321a (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
diff -urN wput/Makefile wput/Makefile
--- wput/Makefile	2006-04-04 19:06:27.000000000 +0100
+++ wput/Makefile	2006-11-06 06:24:58.000000000 +0000
@@ -15,8 +15,10 @@
 
 install: all
 	cd po && $(MAKE) $(MAKEDEFS) $@
-	install -m0755 wput $(bindir)
-	install -m0644 doc/wput.1.gz $(mandir)
+	mkdir -p $(DESTDIR)/$(bindir)
+	mkdir -p $(DESTDIR)/$(mandir)
+	install -m0755 wput $(DESTDIR)/$(bindir)
+	install -m0644 doc/wput.1.gz $(DESTDIR)/$(mandir)
 	@echo "----------------"
 	@echo "Wput installed. See 'wput -h' or 'man wput' for usage information."
 	@echo "Further documentation is located in the doc/USAGE.* files."
diff -urN wput/src/ftp.c wput/src/ftp.c
--- wput/src/ftp.c	2006-04-07 23:14:47.000000000 +0100
+++ wput/src/ftp.c	2006-11-06 06:21:24.000000000 +0000
@@ -88,7 +88,7 @@
  * path and change there again */
 /* error-levels: ERR_RECONNECT, ERR_FAILED, ERR_SKIP (failed for '/'), 1 */
 int try_do_cwd(ftp_con * ftp, char * path, int mkd) {
-	int res;
+	int res = -1;
 	if(!strcmp(path, "."))
 		return mkd;
 	if(!strcmp(path, ".."))
@@ -201,7 +201,7 @@
 }
 
 int open_input_file(_fsession * fsession) {
-	int fd;
+	int fd = -1;
 	int oflags = O_RDONLY;
 	char * cmd;
 	FILE * pipe;
diff -urN wput/src/ftp-ls.c wput/src/ftp-ls.c
--- wput/src/ftp-ls.c	2006-04-06 22:09:18.000000000 +0100
+++ wput/src/ftp-ls.c	2006-11-06 06:21:24.000000000 +0000
@@ -44,6 +44,11 @@
 #include <sys/types.h>
 #include <errno.h>
 
+#ifndef _XOPEN_SOURCE
+# define _XOPEN_SOURCE
+#endif
+#include <time.h>
+
 #include "wget.h"
 #include "utils.h"
 #include "ftp.h"