From ea13ca888b1dcb638ab987825e9b4b74ad070b14 Mon Sep 17 00:00:00 2001 From: Sam O'Connor Date: Wed, 31 Jan 2018 10:01:34 +1100 Subject: [PATCH] fix for https://ci.appveyor.com/project/quinnj/http-jl/build/1.0.472/job/9o3gx0h62eavuncp#L229 --- src/Parsers.jl | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Parsers.jl b/src/Parsers.jl index ae035ea11..80dedeb09 100644 --- a/src/Parsers.jl +++ b/src/Parsers.jl @@ -266,19 +266,19 @@ Return number of bytes of chunk-data. function parse_chunk_size(bytes::AbstractVector{UInt8})::Int - chunk_size = 0 + chunk_size = Int64(0) i = 1 - x = unhex[bytes[i]] + x = Int64(unhex[bytes[i]]) while x != -1 - chunk_size = chunk_size * 16 + x + chunk_size = chunk_size * Int64(16) + x if chunk_size > chunk_size_limit throw(ParseError(:CHUNK_SIZE_EXCEEDS_LIMIT, bytes)) end i += 1 - x = unhex[bytes[i]] + x = Int64(unhex[bytes[i]]) end if i > 1 - return chunk_size + return Int(chunk_size) end throw(ParseError(:INVALID_CHUNK_SIZE, bytes))