arjitkumar / rpms / ftp

Forked from rpms/ftp 5 years ago
Clone

Blame SOURCES/netkit-ftp-0.17-commands-leaks.patch

09d58c
diff -up netkit-ftp-0.17/ftp/cmds.c.orig netkit-ftp-0.17/ftp/cmds.c
09d58c
--- netkit-ftp-0.17/ftp/cmds.c.orig	2011-09-05 14:41:34.000000000 +0200
09d58c
+++ netkit-ftp-0.17/ftp/cmds.c	2011-09-05 14:44:44.000000000 +0200
09d58c
@@ -499,6 +499,9 @@ usage:
09d58c
 	}
09d58c
 	sendrequest(cmd, argv[1], argv[2],
09d58c
 	    argv[1] != oldargv1 || argv[2] != oldargv2);
09d58c
+	if (argv[1] != oldargv1) {
09d58c
+		free(argv[1]);
09d58c
+	}
09d58c
 }
09d58c
 
09d58c
 void mabort(int);