Package: netkit-ftp / 0.17-31

043_tune_non_autologin.diff Patch series | download
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
Description: Only use implicit SYST with auto-login.
 Not every server, nor every ftp-proxy server, is able
 to reply to a SYST command before the user has logged in.
 .
 Do not execute 'dosyst()' in a situation where the user
 has asked for overriding auto-login. In other words,
 execute both of 'dologin()' and 'dosyst()', or execute
 none of them, depending on AUTOLOGIN.
Bug-Debian: http://bugs.debian.org/611284
Forwarded: not-needed
Author: Mats Erik Andersson
Last-Update: 2011-05-23

--- netkit-ftp-0.17/ftp/cmds.c.debian
+++ netkit-ftp-0.17/ftp/cmds.c
@@ -243,9 +243,10 @@
 		(void) strcpy(modename, "stream"), mode = MODE_S;
 		(void) strcpy(structname, "file"), stru = STRU_F;
 		(void) strcpy(bytename, "8"), bytesize = 8;
-		if (autologin)
+		if (autologin) {
 			(void) dologin(argv[1]);
-		dosyst();
+			dosyst();
+		}
 	}
 }