From 2e77fb600aba9970e8cbc623ce9bc5e7bcee7d53 Mon Sep 17 00:00:00 2001 From: Andrew Pamment Date: Wed, 5 Apr 2017 09:42:32 +1000 Subject: [PATCH] experimental ipv6 ftp --- utils/magiftpd/magiftpd.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/utils/magiftpd/magiftpd.c b/utils/magiftpd/magiftpd.c index 869e008..ae7b52f 100644 --- a/utils/magiftpd/magiftpd.c +++ b/utils/magiftpd/magiftpd.c @@ -401,7 +401,8 @@ void handle_PASV(struct ftpserver *cfg, struct ftpclient *client) { socklen_t file_sock_len = sizeof(struct sockaddr_in6); getsockname(client->data_srv_socket, (struct sockaddr*) &file_addr, &file_sock_len); - ipcpy = strdup(client->hostip); + fprintf(stderr, "%s\n", client->hostip); + ipcpy = strdup(&client->hostip[8]); ipptr = strtok(ipcpy, ".");