diff --git a/cli/lz/ulzdec.c b/cli/lz/ulzdec.c index 1841197..941ea0b 100644 --- a/cli/lz/ulzdec.c +++ b/cli/lz/ulzdec.c @@ -1,7 +1,7 @@ #include #include -/* cc ulzdec.c -o ulzdec && ./ulzdec compressed.bin */ +/* cc ulzdec.c -o ulzdec && ./ulzdec a.ulz b.bin */ static int error(const char *name, const char *msg) @@ -10,12 +10,12 @@ error(const char *name, const char *msg) return 0; } -char *mem, *ptr; +char *mem; int decode_ulz(FILE *src) { - char c, *copy; + char c, *copy, *ptr; short i, length; ptr = mem = malloc(0x10000); while((c = getc(src)) != EOF) { diff --git a/cli/lz/ulzenc.c b/cli/lz/ulzenc.c index 0213a30..9eb08b9 100644 --- a/cli/lz/ulzenc.c +++ b/cli/lz/ulzenc.c @@ -1,9 +1,7 @@ #include #include -/* cc ulzenc.c -o ulzenc && ./ulzenc example.txt */ - -enum { MinMatchLength = 4 }; +/* cc ulzenc.c -o ulzenc && ./ulzenc a.bin b.ulz */ static int error(const char *name, const char *msg) @@ -12,6 +10,8 @@ error(const char *name, const char *msg) return 0; } +enum { MinMatchLength = 4 }; + char *raw, *mem; int