Adar Dembo has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/14587 )

Change subject: [compression] Use new lz4 API
......................................................................


Patch Set 1:

(1 comment)

http://gerrit.cloudera.org:8080/#/c/14587/1/src/kudu/util/compression/compression_codec.cc
File src/kudu/util/compression/compression_codec.cc:

http://gerrit.cloudera.org:8080/#/c/14587/1/src/kudu/util/compression/compression_codec.cc@184
PS1, Line 184:     if (n != uncompressed_length) {
Are you sure comparing against uncompressed_length makes sense? Seems like it 
could be OK for it not to use the entire destination buffer. The function 
comment for LZ4_decompress_safe says:

/*! LZ4_decompress_safe() :
    compressedSize : is the exact complete size of the compressed block.
    dstCapacity : is the size of destination buffer, which must be already 
allocated.
   @return : the number of bytes decompressed into destination buffer 
(necessarily <= dstCapacity)
             If destination buffer is not large enough, decoding will stop and 
output an error code (negative value).
             If the source stream is detected malformed, the function will stop 
decoding and return a negative result.
    Note : This function is protected against malicious data packets (never 
writes outside 'dst' buffer, nor read outside 'source' buffer).
*/



--
To view, visit http://gerrit.cloudera.org:8080/14587
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ib343fda7fff1d14ee7bc551be3ac87b068504359
Gerrit-Change-Number: 14587
Gerrit-PatchSet: 1
Gerrit-Owner: Anonymous Coward <[email protected]>
Gerrit-Reviewer: Adar Dembo <[email protected]>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Comment-Date: Wed, 30 Oct 2019 16:49:50 +0000
Gerrit-HasComments: Yes

Reply via email to