| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The following command doesn't work as intended
```
cd
git clone https://github.com/lz4/lz4.git
cd lz4
make usan MOREFLAGS='-Wcomma -Werror'
```
```
Cleaning completed
cc: error: unrecognized command line option ‘-Wcomma’; did you mean ‘-Wcomment’?
make[3]: *** [<builtin>: ../lib/lz4.o] Error 1
make[2]: *** [Makefile:65: lz4] Error 2
make[1]: *** [Makefile:133: test] Error 2
make: *** [Makefile:158: usan] Error 2
```
Because the following part of the `Makefile` doesn't propagate `CC`, `CFLAGS` and `LDFLAGS` to child `$(MAKE)` properly.
```
.PHONY: usan
usan: CC = clang
usan: CFLAGS = -O3 -g -fsanitize=undefined -fno-sanitize-recover=undefined -fsanitize-recover=pointer-overflow
usan: LDFLAGS = $(CFLAGS)
usan: clean
$(MAKE) test FUZZER_TIME="-T30s" NB_LOOPS=-i1
```
We need explicit propagation for child process
```
- $(MAKE) test FUZZER_TIME="-T30s" NB_LOOPS=-i1
+ CC=$(CC) CFLAGS=$(CFLAGS) LDFLAGS=$(LDFLAGS) $(MAKE) test FUZZER_TIME="-T30s" NB_LOOPS=-i1
```
After that, `make usan` works and it shows expected runtime error.
```
$ make usan MOREFLAGS='-Wcomma -Werror'
Cleaning completed
../lib/lz4frame.c:907:25: runtime error: applying non-zero offset 65536 to null pointer
SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior ../lib/lz4frame.c:907:25 in
../lib/lz4frame.c:907:58: runtime error: applying zero offset to null pointer
SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior ../lib/lz4frame.c:907:58 in
...
```
Please note that `make usan` is working at travis-ci. Because `.travis.yml` has the following [explicit `compiler:` setting](https://github.com/lz4/lz4/blob/7a966c1511816b53ac93aa2f2a2ff97e036a4a60/.travis.yml#L66).
```
- name: (Trusty) USan test
dist: trusty
compiler: clang
script:
- make usan MOREFLAGS=-Wcomma -Werror
```
|
| |
|
|
|
|
| |
so now, `%p` _requires_ a `void*` pointer ?
|
|
|
|
| |
seems to require explicit environment variables
|
| |
|
|
|
|
|
| |
remove usage of include Makefile.inc in too Makefile
as it seems to somehow unexport CFLAGS ...
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
| |
the way `base` is used must allow 2-complement address overflow.
`base` is effectively a virtual pointer, never dereferenced directly.
What matters is `base + index`.
This is the address that will be dereference and must be valid (it is properly validated).
|
|
|
|
|
|
| |
which now fails with a clear error as intended
(not just print a status and move on).
should be reproduced on travisCI
|
|
|
|
| |
Fixes #852.
|
| |
|
| |
|
|
|
|
|
| |
- only play listTest with `make test`, not `make all` which is limited to build
- update `clangtest`, so that it's possible to disable O3 optimization, for faster processing
|
| |
|
|
|
|
| |
"install" in one place to try to isolate it.
|
| |
|
|
|
|
|
|
|
|
| |
- promoted LZ4_resetStreamHC_fast() to stable
- moved LZ4_resetStreamHC() to deprecated (but do not generate a warning yet)
- Updated doc, to highlight difference between init and reset
- switched all invocations of LZ4_resetStreamHC() onto LZ4_initStreamHC()
- misc: ensure `make all` also builds /tests
|
| |
|
| |
|
|
|
|
|
|
| |
as Makefile target and Travis CI test.
Fixed last cppcheck warnings in tests and examples
|
|
|
|
|
|
|
| |
as detected in #485 by @JoachimSchneider.
Refactored the c_standards tests
so that these issues get automatically detected in CI tests.
|
| |
|
| |
|
|
|
|
| |
lz4 1.8.2 works fine on Haiku and passes all tests.
|
| |
|
|
|
|
| |
to catch `//` comments
|
|
|
|
|
|
|
|
|
| |
`make all` will trigger several sub-directory makefiles.
several of them need `liblz4.a`.
When built with `-j#`, there are several concurrent liblz4.a built
Make liblz4.a a dependency, which is built once,
before moving to sub-directory Makefiles
|
|
|
|
|
|
|
|
|
|
| |
according to GNU Makefile conventions,
the Makefile should feature a make check target
to self-test the generated program:
https://www.gnu.org/prep/standards/html_node/Standard-Targets.html .
this is much less thorough and less taxing than `make test`,
and can be run on any target in a reasonable timeframe (several seconds).
|
|
|
|
| |
static library *.a must come after source files *.c on linux
|
|\ |
|
| | |
|
|/
|
|
| |
to better reflect LZ4F API usage.
|
| |
|
|
|
|
| |
since it's not needed.
|
|
|
|
|
|
|
|
|
| |
instead of selected at compilation time depending on a macro.
This design makes it possible to have a single binary which supports both modes.
An advantageous side effect is that when doing `make; make install`
no additional binary is created during `make install`
(it used to create `lz4c`, because `make` would only build `lz4`)
|
|
|
|
|
|
| |
supports lowercase directory variables
add an "Installation" section in README.md
added an INSTALL file
|
|
|
|
| |
and added entry "make list"
|
|
|
|
|
| |
to automatically build manual files with
make all
|
|\
| |
| | |
Dev
|
| | |
|
|/ |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|