You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If a LZ4Decompressor cannot decode the frame header, finalize() gives a malloc error.
julia>using CodecLz4
julia> codec =LZ4Decompressor()
CodecLz4.LZ4Decompressor(Base.RefValue{Ptr{CodecLz4.LZ4F_dctx}}(Ptr{CodecLz4.LZ4F_dctx} @0x0000000000000000))
julia>try
data =transcode(codec, "not properly formatted")
println(data)
catch e
println(e)
finallytry
CodecLz4.check_context_initialized(codec.dctx[])
println("codec exists")
catchprintln("empty codec")
end
CodecLz4.TranscodingStreams.finalize(codec)
endErrorException("LZ4F_decompress: ERROR_frameType_unknown")
codec exists
julia(25795,0x7fffa6174340) malloc:*** error for object 0x309371a21220309: pointer being freed was not allocated
*** set a breakpoint in malloc_error_break to debug
signal (6): Abort trap:6
Looking into the LZ4 source code here, it seems that the temporary buffers don't get allocated properly before they are freed.
The text was updated successfully, but these errors were encountered:
If a
LZ4Decompressor
cannot decode the frame header,finalize()
gives a malloc error.Looking into the LZ4 source code here, it seems that the temporary buffers don't get allocated properly before they are freed.
The text was updated successfully, but these errors were encountered: