1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

vweb: fix empty post request blocking

This commit is contained in:
taojy123
2019-12-12 00:20:46 +08:00
committed by Alexander Medvednikov
parent 7dcd47369b
commit 28f76f10db
2 changed files with 56 additions and 25 deletions

View File

@ -19,6 +19,11 @@ pub fn new_builder(initial_size int) Builder {
}
}
pub fn (b mut Builder) write_bytes(bytes byteptr, howmany int) {
b.buf.push_many(bytes, howmany)
b.len += howmany
}
pub fn (b mut Builder) write_b(data byte) {
b.buf << data
b.len++