changeset 881:c010094bd60b

2007-2-26 Brian Masney <masneyb@gftp.org> * lib/rfc959.c (rfc959_read_response) - log any commands that return a 4xx or 5xx with the gftp_logging_error priority. (closes #411777)
author masneyb
date Mon, 26 Feb 2007 22:53:57 +0000
parents 18850d856cf6
children ffeaa0c77643
files ChangeLog lib/rfc959.c
diffstat 2 files changed, 11 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Sun Feb 25 20:49:57 2007 +0000
+++ b/ChangeLog	Mon Feb 26 22:53:57 2007 +0000
@@ -1,3 +1,7 @@
+2007-2-26 Brian Masney <masneyb@gftp.org>
+	* lib/rfc959.c (rfc959_read_response) - log any commands that return
+	a 4xx or 5xx with the gftp_logging_error priority. (closes #411777)
+
 2007-2-14 Brian Masney <masneyb@gftp.org>
 	* lib/gftp.h src/gtk/gtkui.c src/uicommon/gftpui.c - added refreshing
 	field to the gftp_request structure. If this is set in
--- a/lib/rfc959.c	Sun Feb 25 20:49:57 2007 +0000
+++ b/lib/rfc959.c	Mon Feb 26 22:53:57 2007 +0000
@@ -122,8 +122,13 @@
 	  strncpy (code, tempstr, 3);
 	  code[3] = ' ';
 	}
-      request->logging_function (gftp_logging_recv, request,
-				 "%s\n", tempstr);
+
+      if (*tempstr == '4' || *tempstr == '5')
+        request->logging_function (gftp_logging_error, request,
+  				   "%s\n", tempstr);
+      else
+        request->logging_function (gftp_logging_recv, request,
+  				   "%s\n", tempstr);
     }
   while (strncmp (code, tempstr, 4) != 0);