ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/gvpe/src/connection.C
(Generate patch)

Comparing gvpe/src/connection.C (file contents):
Revision 1.115 by root, Thu Jun 30 16:31:00 2016 UTC vs.
Revision 1.116 by root, Mon Apr 1 03:10:26 2019 UTC

51 51
52#include "netcompat.h" 52#include "netcompat.h"
53 53
54#define MAGIC "gvpe\xbd\xc6\xdb\x82" // 8 bytes of magic 54#define MAGIC "gvpe\xbd\xc6\xdb\x82" // 8 bytes of magic
55 55
56#define LZF_STATE_ARG 1
56#define ULTRA_FAST 1 57#define ULTRA_FAST 1
57#define HLOG 15 58#define HLOG 15
58#include "lzf/lzf.h" 59#define INIT_HTAB 0
59#include "lzf/lzf_c.c" 60#include "lzf/lzf_c.c"
60#include "lzf/lzf_d.c" 61#include "lzf/lzf_d.c"
61 62
62////////////////////////////////////////////////////////////////////////////// 63//////////////////////////////////////////////////////////////////////////////
63 64
446#if ENABLE_COMPRESSION 447#if ENABLE_COMPRESSION
447 u8 cdata[MAX_MTU]; 448 u8 cdata[MAX_MTU];
448 449
449 if (conn->features & FEATURE_COMPRESSION) 450 if (conn->features & FEATURE_COMPRESSION)
450 { 451 {
452 static LZF_STATE lzf_state;
451 u32 cl = lzf_compress (d, l, cdata + 2, (l - 2) & ~7); 453 u32 cl = lzf_compress (d, l, cdata + 2, (l - 2) & ~7, lzf_state);
452 454
453 if (cl) 455 if (cl)
454 { 456 {
455 type = PT_DATA_COMPRESSED; 457 type = PT_DATA_COMPRESSED;
456 d = cdata; 458 d = cdata;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines