Housekeeping

This commit is contained in:
neauoire 2023-11-16 20:53:01 -08:00
parent 6df064d8cf
commit 2a10a1cf81
2 changed files with 6 additions and 6 deletions

View File

@ -1,7 +1,7 @@
#include <stdio.h>
#include <stdlib.h>
/* 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) {

View File

@ -1,9 +1,7 @@
#include <stdio.h>
#include <stdlib.h>
/* 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