mirror of
https://github.com/openappsec/openappsec.git
synced 2025-09-29 19:24:26 +03:00
sync code
This commit is contained in:
@@ -39,7 +39,7 @@ public:
|
||||
init()
|
||||
{
|
||||
server_fd = socket(AF_INET, SOCK_STREAM, 0);
|
||||
dbgAssert(server_fd >= 0) << "Failed to open a socket";
|
||||
dbgAssert(server_fd >= 0) << AlertInfo(AlertTeam::CORE, "messaging i/s") << "Failed to open a socket";
|
||||
int socket_enable = 1;
|
||||
setsockopt(server_fd, SOL_SOCKET, SO_REUSEADDR, &socket_enable, sizeof(int));
|
||||
|
||||
|
@@ -92,7 +92,10 @@ string
|
||||
HTTPResponse::toString() const
|
||||
{
|
||||
auto code = status_code_to_string.find(status_code);
|
||||
dbgAssert(code != status_code_to_string.end()) << "Unknown status code " << int(status_code);
|
||||
dbgAssert(code != status_code_to_string.end())
|
||||
<< AlertInfo(AlertTeam::CORE, "messaging i/s")
|
||||
<< "Unknown status code "
|
||||
<< int(status_code);
|
||||
|
||||
return "[Status-code]: " + code->second + ", [Body]: " + (body.empty() ? "{}" : body);
|
||||
}
|
||||
|
Reference in New Issue
Block a user