diff options
| author | Dan Engelbrecht <[email protected]> | 2024-06-14 22:12:57 +0200 |
|---|---|---|
| committer | GitHub Enterprise <[email protected]> | 2024-06-14 22:12:57 +0200 |
| commit | ee5fcbce34eaef87ffced2a993c8443af4af4fe2 (patch) | |
| tree | 7eeb7df5c48d11a2653e1536f39f4f0bf17f0b53 /src/zenhttp/servers | |
| parent | workspace share path hardening (#95) (diff) | |
| download | zen-ee5fcbce34eaef87ffced2a993c8443af4af4fe2.tar.xz zen-ee5fcbce34eaef87ffced2a993c8443af4af4fe2.zip | |
don't assert that we have moved bytes if source block is zero size (#97)
* don't assert that we have moved bytes if source block is zero size
* handle invalid session ids gracefully
Diffstat (limited to 'src/zenhttp/servers')
| -rw-r--r-- | src/zenhttp/servers/httpparser.cpp | 2 | ||||
| -rw-r--r-- | src/zenhttp/servers/httpsys.cpp | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/zenhttp/servers/httpparser.cpp b/src/zenhttp/servers/httpparser.cpp index b848a5243..6829faa4a 100644 --- a/src/zenhttp/servers/httpparser.cpp +++ b/src/zenhttp/servers/httpparser.cpp @@ -149,7 +149,7 @@ HttpRequestParser::AppendCurrentHeader() } else if (HeaderHash == HashSession) { - m_SessionId = Oid::FromHexString(HeaderValue); + m_SessionId = Oid::TryFromHexString(HeaderValue); } else if (HeaderHash == HashRequest) { diff --git a/src/zenhttp/servers/httpsys.cpp b/src/zenhttp/servers/httpsys.cpp index 2b97e3f25..ac17d3ba0 100644 --- a/src/zenhttp/servers/httpsys.cpp +++ b/src/zenhttp/servers/httpsys.cpp @@ -1668,7 +1668,7 @@ HttpSysServerRequest::ParseSessionId() const { if (Header.RawValueLength == Oid::StringLength) { - return Oid::FromHexString({Header.pRawValue, Header.RawValueLength}); + return Oid::TryFromHexString({Header.pRawValue, Header.RawValueLength}); } } } |