renamed files

This commit is contained in:
Paul Cruz 2017-07-05 09:57:50 -07:00
parent c9f49198b8
commit 5df4cb0530
4 changed files with 12 additions and 8 deletions

View File

@ -18,15 +18,15 @@ CFLAGS += $(DEBUGFLAGS)
CFLAGS += $(MOREFLAGS)
FLAGS = $(CPPFLAGS) $(CFLAGS) $(LDFLAGS)
all: clean v1 v2
v1: $(ZSTD_FILES) v1.c
all: clean single multi
single: $(ZSTD_FILES) single.c
$(CC) $(FLAGS) $^ -o $@
v2: $(ZSTD_FILES) v2.c
multi: $(ZSTD_FILES) multi.c
$(CC) $(FLAGS) $^ -o $@
clean:
@$(RM) -f v1 v2
@$(RM) -f single multi
@$(RM) -rf *.dSYM
@$(RM) -f tmp*
@echo "finished cleaning"

View File

@ -174,7 +174,7 @@ static void* outputThread(void* arg)
size_t const compressedSize = job->compressedSize;
if (ZSTD_isError(compressedSize)) {
DISPLAY("Error: an error occurred during compression\n");
return arg;
return arg;
}
{
size_t const writeSize = fwrite(ctx->jobs[currJob].dst.start, 1, compressedSize, ctx->dstFile);
@ -253,7 +253,7 @@ static int createCompressionJob(adaptCCtx* ctx, BYTE* data, size_t srcSize)
/* return 0 if successful, else return error */
int main(int argCount, const char* argv[])
{
if (argCount < 2) {
if (argCount < 3) {
DISPLAY("Error: not enough arguments\n");
return 1;
}

View File

@ -1,2 +1,6 @@
make clean v2
./v2 tests/test2048.pdf tmp.zst
make clean multi
./multi tests/test2048.pdf tmp.zst
zstd -d tmp.zst
diff tmp tests/test2048.pdf
echo "diff test complete"
make clean