mirror of
https://github.com/mtheall/ftpd.git
synced 2024-11-23 09:39:43 +00:00
explicitly truncate path
This commit is contained in:
parent
4f98119edb
commit
10b46172fe
@ -3016,7 +3016,7 @@ FTP_DECLARE(CWD)
|
||||
|
||||
/* copy the path into the cwd */
|
||||
strncpy(session->cwd, session->buffer, sizeof(session->cwd));
|
||||
|
||||
session->cwd[sizeof(session->cwd)-1] = '\0';
|
||||
ftp_send_response(session, 200, "OK\r\n");
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user