diff options
| author | Adam Ierymenko <[email protected]> | 2017-01-19 14:54:39 -0800 |
|---|---|---|
| committer | Adam Ierymenko <[email protected]> | 2017-01-19 14:54:39 -0800 |
| commit | 7612bf3302eef8a49658eaeca09504be588f6398 (patch) | |
| tree | 42ac2d18d0a081b304abebe8e4bbb083a2b5421b /node/Packet.cpp | |
| parent | ba158d8dc6d05db2fc330913d0ab76af1e306055 (diff) | |
Fix LZ4 warning.
Diffstat (limited to 'node/Packet.cpp')
| -rw-r--r-- | node/Packet.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/node/Packet.cpp b/node/Packet.cpp index bdbc5fe4..6d1f49e8 100644 --- a/node/Packet.cpp +++ b/node/Packet.cpp @@ -125,7 +125,7 @@ bool Packet::compress() unsigned char buf[ZT_PROTO_MAX_PACKET_LENGTH * 2]; if ((!compressed())&&(size() > (ZT_PACKET_IDX_PAYLOAD + 32))) { int pl = (int)(size() - ZT_PACKET_IDX_PAYLOAD); - int cl = LZ4_compress((const char *)field(ZT_PACKET_IDX_PAYLOAD,(unsigned int)pl),(char *)buf,pl); + int cl = LZ4_compress_default((const char *)field(ZT_PACKET_IDX_PAYLOAD,(unsigned int)pl),(char *)buf,pl,ZT_PROTO_MAX_PACKET_LENGTH * 2); if ((cl > 0)&&(cl < pl)) { (*this)[ZT_PACKET_IDX_VERB] |= (char)ZT_PROTO_VERB_FLAG_COMPRESSED; setSize((unsigned int)cl + ZT_PACKET_IDX_PAYLOAD); |
