fix PWD
This commit is contained in:
parent
d8f7f66b5e
commit
abcad46414
@ -861,7 +861,13 @@ void handle_PWD(struct ftpserver *cfg, struct ftpclient *client) {
|
||||
exit(-1);
|
||||
}
|
||||
|
||||
sprintf(buffer, "257 \"%s\"\r\n", client->current_path);
|
||||
if (client->current_path == client->user->indir) {
|
||||
sprintf(buffer, "257 \"/in\"\r\n");
|
||||
} else if (client->current_path == client->user->outdir) {
|
||||
sprintf(buffer, "257 \"/out\"\r\n");
|
||||
} else {
|
||||
sprintf(buffer, "257 \"/\"\r\n");
|
||||
}
|
||||
send_msg(client, buffer);
|
||||
free(buffer);
|
||||
}
|
||||
|
Reference in New Issue
Block a user