mirror of
https://github.com/ziglang/zig.git
synced 2025-12-08 07:13:08 +00:00
std.http.Server: no more dynamic allocation
In particular remove OutOfMemory from the error set for parsing client http headers.
This commit is contained in:
parent
68d3e103b7
commit
2df3de1e20
@ -96,7 +96,7 @@ pub const Request = struct {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
pub const ParseError = Allocator.Error || error{
|
pub const ParseError = error{
|
||||||
UnknownHttpMethod,
|
UnknownHttpMethod,
|
||||||
HttpHeadersInvalid,
|
HttpHeadersInvalid,
|
||||||
HttpHeaderContinuationsUnsupported,
|
HttpHeaderContinuationsUnsupported,
|
||||||
@ -612,7 +612,6 @@ const http = std.http;
|
|||||||
const mem = std.mem;
|
const mem = std.mem;
|
||||||
const net = std.net;
|
const net = std.net;
|
||||||
const Uri = std.Uri;
|
const Uri = std.Uri;
|
||||||
const Allocator = mem.Allocator;
|
|
||||||
const assert = std.debug.assert;
|
const assert = std.debug.assert;
|
||||||
|
|
||||||
const Server = @This();
|
const Server = @This();
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user