httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wr...@apache.org
Subject svn commit: r581482 - /httpd/mod_ftp/trunk/modules/ftp/ftp_protocol.c
Date Wed, 03 Oct 2007 03:02:19 GMT
Author: wrowe
Date: Tue Oct  2 20:02:18 2007
New Revision: 581482

URL: http://svn.apache.org/viewvc?rev=581482&view=rev
Log:
ftp_send_response() needs serious refactoring, to always permit the caller
to customize the error response message based on existing conditions.

Modified:
    httpd/mod_ftp/trunk/modules/ftp/ftp_protocol.c

Modified: httpd/mod_ftp/trunk/modules/ftp/ftp_protocol.c
URL: http://svn.apache.org/viewvc/httpd/mod_ftp/trunk/modules/ftp/ftp_protocol.c?rev=581482&r1=581481&r2=581482&view=diff
==============================================================================
--- httpd/mod_ftp/trunk/modules/ftp/ftp_protocol.c (original)
+++ httpd/mod_ftp/trunk/modules/ftp/ftp_protocol.c Tue Oct  2 20:02:18 2007
@@ -769,6 +769,17 @@
         ftp_reply(fc, c->output_filters, r->pool, FTP_REPLY_BAD_SEQUENCE, 0, 
                   "Bad sequence of commands");
         break;
+    case FTP_REPLY_BAD_PROTOCOL:
+        /* XXX This is really crufty, the given server may be configured
+         * to support only an IPv4 or IPv6 binding
+         */
+        ftp_reply(fc, c->output_filters, r->pool, FTP_REPLY_BAD_PROTOCOL, 0, 
+#if APR_HAVE_IPV6
+                  "Network protocol not supported, use (1,2)");
+#else
+                  "Network protocol not supported, use (1)");
+#endif
+        break;
     case FTP_REPLY_PROT_NOT_SUPPORTED:
         ftp_reply(fc, c->output_filters, r->pool, 
                   FTP_REPLY_PROT_NOT_SUPPORTED, 0,



Mime
View raw message