]> git.sesse.net Git - betaftpd/commitdiff
ASCII mode is now displayed in STAT replies (it used to say Image all the time
authorsgunderson <sgunderson>
Thu, 27 Jul 2000 00:03:42 +0000 (00:03 +0000)
committersgunderson <sgunderson>
Thu, 27 Jul 2000 00:03:42 +0000 (00:03 +0000)
cmds.c

diff --git a/cmds.c b/cmds.c
index 0af47825ef0aaadc3e153aae4db930209ba2c055..6c277af284ba815871f7e36dab8e4059af1b20f9 100644 (file)
--- a/cmds.c
+++ b/cmds.c
@@ -936,11 +936,19 @@ int cmd_stat(struct conn * const c)
                            "     BetaFTPD version " VERSION " (http://members.xoom.com/sneeze/betaftpd.html)\r\n"
                            "     Connected to %s\r\n"
                            "     Control connection state: %s\r\n"
+#if WANT_ASCII
+                           "     TYPE: %s; STRUcture: File; transfer MODE: Stream\r\n"
+#else
                            "     TYPE: Image; STRUcture: File; transfer MODE: Stream\r\n"
+#endif
                            "     Data connection state: %s\r\n"
                            "211 End of status\r\n",
                                inet_ntoa(((struct sockaddr_in *)(&(c->addr)))->sin_addr),
-                               conn_state[c->auth], (f) ? ftran_state[f->state] : ftran_state[0]);
+                               conn_state[c->auth],
+#if WANT_ASCII
+                               (c->ascii_mode == 1) ? "ASCII, FORM: Nonprint" : "Image",
+#endif
+                               (f) ? ftran_state[f->state] : ftran_state[0]);
 
        i = strlen(buf);