summaryrefslogtreecommitdiff
path: root/lzf_c.c
diff options
context:
space:
mode:
authorroot <root>2007-11-13 11:02:28 +0000
committerroot <root>2007-11-13 11:02:28 +0000
commitd73fdbeb9a5b1d65e82c22411d76fc117ad67296 (patch)
treef259427b99d8d02b56cab618cbf867946b8e3b3f /lzf_c.c
parent2377e800b66884301825c071cc9667583d0b2e31 (diff)
*** empty log message ***
Diffstat (limited to 'lzf_c.c')
-rw-r--r--lzf_c.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lzf_c.c b/lzf_c.c
index bf86f1d..48bdd6a 100644
--- a/lzf_c.c
+++ b/lzf_c.c
@@ -159,12 +159,12 @@ lzf_compress (const void *const in_data, unsigned int in_len,
unsigned int maxlen = in_end - ip - len;
maxlen = maxlen > MAX_REF ? MAX_REF : maxlen;
- if (expect_false (op + 1 + 3 >= out_end))
- return 0;
-
op [- lit - 1] = lit - 1; /* stop run */
op -= !lit; /* undo run if length is zero */
+ if (expect_false (op + 3 + 1 >= out_end))
+ return 0;
+
for (;;)
{
if (expect_true (maxlen > 16))