Обновить sk1/compressor.c
This commit is contained in:
parent
32a48a7f2a
commit
10cc53b3bb
@ -217,7 +217,7 @@ int compressFile(const char* input_file_name, const char* output_file_name) {
|
|||||||
byte <<= (8 - bitCount);
|
byte <<= (8 - bitCount);
|
||||||
fwrite(&byte, sizeof(unsigned char), 1, outputFile);
|
fwrite(&byte, sizeof(unsigned char), 1, outputFile);
|
||||||
}
|
}
|
||||||
|
freeHuffmanTree(root);
|
||||||
fclose(inputFile);
|
fclose(inputFile);
|
||||||
fclose(outputFile);
|
fclose(outputFile);
|
||||||
return 0;
|
return 0;
|
||||||
@ -270,7 +270,7 @@ int decompressFile(const char* input_file_name, const char* output_file_name) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
freeHuffmanTree(root);
|
||||||
fclose(inputFile);
|
fclose(inputFile);
|
||||||
fclose(outputFile);
|
fclose(outputFile);
|
||||||
return 0;
|
return 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user