Integrate LZ4 library, compress the ramdisk
All checks were successful
Build documentation / build-and-deploy (push) Successful in 1m53s
All checks were successful
Build documentation / build-and-deploy (push) Successful in 1m53s
This commit is contained in:
21
lz4/tests/test-lz4-frame-concatenation.sh
Executable file
21
lz4/tests/test-lz4-frame-concatenation.sh
Executable file
@@ -0,0 +1,21 @@
|
||||
#!/bin/sh
|
||||
|
||||
FPREFIX="tmp-lfc"
|
||||
|
||||
set -e
|
||||
remove () {
|
||||
rm $FPREFIX*
|
||||
}
|
||||
|
||||
trap remove EXIT
|
||||
|
||||
set -x
|
||||
|
||||
echo > $FPREFIX-empty
|
||||
echo hi > $FPREFIX-nonempty
|
||||
cat $FPREFIX-nonempty $FPREFIX-empty $FPREFIX-nonempty > $FPREFIX-src
|
||||
lz4 -zq $FPREFIX-empty -c > $FPREFIX-empty.lz4
|
||||
lz4 -zq $FPREFIX-nonempty -c > $FPREFIX-nonempty.lz4
|
||||
cat $FPREFIX-nonempty.lz4 $FPREFIX-empty.lz4 $FPREFIX-nonempty.lz4 > $FPREFIX-concat.lz4
|
||||
lz4 -d $FPREFIX-concat.lz4 -c > $FPREFIX-result
|
||||
cmp $FPREFIX-src $FPREFIX-result
|
||||
Reference in New Issue
Block a user