restore accidently deleted part

This commit is contained in:
Andrew Pamment 2017-04-05 09:32:09 +10:00
parent 4ff178e9f2
commit ddd10b3081

View File

@ -402,6 +402,12 @@ void handle_PASV(struct ftpserver *cfg, struct ftpclient *client) {
getsockname(client->data_srv_socket, (struct sockaddr*) &file_addr, &file_sock_len); getsockname(client->data_srv_socket, (struct sockaddr*) &file_addr, &file_sock_len);
strcpy(buffer, "227 Entering Passive Mode ("); strcpy(buffer, "227 Entering Passive Mode (");
while (ipptr != NULL) {
sprintf(buffer, "%s%s,", buffer, ipptr);
ipptr = strtok(NULL, ".");
}
sprintf(buffer, "%s%d,%d)\r\n", buffer, port / 256, port % 256);
send_msg(client, buffer); send_msg(client, buffer);
free(ipcpy); free(ipcpy);
} }