mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-09-02 18:31:22 +02:00
nhttpd: fix stack buffer overflow
This commit is contained in:
@@ -486,7 +486,8 @@ std::string CySocket::ReceiveLine() {
|
||||
else
|
||||
break;
|
||||
}
|
||||
buffer[++bytes_gotten] = '\0';
|
||||
if (bytes_gotten < MAX_LINE_BUFFER - 1)
|
||||
buffer[++bytes_gotten] = '\0';
|
||||
result.assign(buffer, bytes_gotten);
|
||||
|
||||
return result;
|
||||
|
Reference in New Issue
Block a user