Philippe Antoine
34af886238
fuzz: improve coverage by maybe stopping parser
2024-01-16 11:08:44 +01:00
Sebastian Pipping
2640b1d97c
Merge pull request #799 from libexpat/ci-fuzzing
...
Make CI run fuzzing regression tests (fixes #367 )
2024-01-16 02:26:43 +01:00
Sebastian Pipping
c47e191797
Merge pull request #803 from libexpat/fix-cppcheck-ci
...
Fix Cppcheck CI for Cppcheck 2.13.0
2024-01-16 01:14:12 +01:00
Sebastian Pipping
24ffba44bd
Make CI run fuzzing regression tests
2024-01-15 23:57:02 +01:00
Sebastian Pipping
73ebe0bfb3
fuzz: Address warning -Wunused-function with regard to sip24_valid
2024-01-15 23:57:02 +01:00
Sebastian Pipping
ed38687779
mass-cppcheck.sh: Fix for Cppcheck 2.13.0
...
Cppcheck output was:
> expat/lib/xmlparse.c:67:4: error: #error XML_GE (for general entities) must be defined, [..]
> # error XML_GE (for general entities) must be defined, [..]
> ^
2024-01-15 23:29:19 +01:00
Sebastian Pipping
3ff1d00dc2
cppcheck.yml: Bump to macOS 12
...
Homebrew output was:
> Warning: You are using macOS 11.
> We (and Apple) do not provide support for this old version.
> [..]
2024-01-15 23:29:19 +01:00
Sebastian Pipping
9e603b35e0
Merge pull request #802 from libexpat/dependabot/github_actions/actions/upload-artifact-4.1.0
...
Actions(deps): Bump actions/upload-artifact from 4.0.0 to 4.1.0
2024-01-15 17:06:21 +01:00
dependabot[bot]
2d9bc9aec6
Actions(deps): Bump actions/upload-artifact from 4.0.0 to 4.1.0
...
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact ) from 4.0.0 to 4.1.0.
- [Release notes](https://github.com/actions/upload-artifact/releases )
- [Commits](c7d193f32e...1eb3cb2b3e
)
---
updated-dependencies:
- dependency-name: actions/upload-artifact
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
2024-01-15 12:39:38 +00:00
Sebastian Pipping
19af57f2dd
Merge pull request #800 from libexpat/clang-tidy-more
...
clang-tidy: Address warnings `readability-avoid-const-params-in-decls` and `readability-named-parameter`
2024-01-13 01:59:22 +01:00
Sebastian Pipping
226a1527cf
clang-tidy: Address warning readability-named-parameter
2024-01-12 23:27:19 +01:00
Sebastian Pipping
225ebd45e1
clang-tidy: Address warning readability-avoid-const-params-in-decls
...
clang-tidy output was:
> [..]/tests/handlers.h:502:64: error: parameter 'index' is const-qualified in the function declaration; const-qualification of parameters only has an effect in function definitions [readability-avoid-const-params-in-decls,-warnings-as-errors]
> 502 | _handler_record_get(const struct handler_record_list *storage, const int index,
> | ^~~~~
> [..]/tests/handlers.h:503:39: error: parameter 'line' is const-qualified in the function declaration; const-qualification of parameters only has an effect in function definitions [readability-avoid-const-params-in-decls,-warnings-as-errors]
> 503 | const char *file, const int line);
> | ^~~~~
2024-01-12 22:19:05 +01:00
Sebastian Pipping
7664ecdbae
Merge pull request #798 from libexpat/clang-tidy
...
Make GitHub Actions enforce clang-tidy clean code + address current clang-tidy warnings
2024-01-12 21:38:35 +01:00
Sebastian Pipping
f832f7b981
Make GitHub Actions enforce clang-tidy clean code
2024-01-12 17:26:50 +01:00
Sebastian Pipping
10cded2493
tests/basic_tests.c: Address clang-tidy warning clang-analyzer-core.NullDereference
...
clang-tidy output was:
> [..]/tests/basic_tests.c:2083:19: warning: Dereference of null pointer [clang-analyzer-core.NullDereference]
> 2083 | errorFlags |= ((model[0].type == XML_CTYPE_SEQ) ? 0 : (1u << 2));
> | ^~~~~~~~~~~~~
2024-01-12 17:25:27 +01:00
Sebastian Pipping
e23c300f25
tests/acc_tests.c: Address clang-tidy warning clang-analyzer-core.NonNullParamChecker
...
clang-tidy output was:
> [..]/tests/acc_tests.c:368:9: warning: Null pointer passed to 1st parameter expecting 'nonnull' [clang-analyzer-core.NonNullParamChecker]
> 368 | if (strlen(printable) < (size_t)1)
> | ^ ~~~~~~~~~
Note: It was harmless because fail(..) right before catches that case.
2024-01-12 17:25:27 +01:00
Sebastian Pipping
0b424cb9ae
examples/element_declarations.c: Simplify first call to stackPushMalloc
...
.. where stackTop is NULL anyway
2024-01-12 17:25:27 +01:00
Sebastian Pipping
0ebca2b10f
examples/element_declarations.c: Fix memleak in dumpContentModel on OOM
...
clang-tidy output was:
> [..]/examples/element_declarations.c:163:16: warning: Potential leak of memory pointed to by 'stackTop' [clang-analyzer-unix.Malloc]
> 163 | return false;
> | ^
2024-01-12 04:46:47 +01:00
Sebastian Pipping
716fd10bd4
Merge pull request #797 from catenacyber/fuzzcov
...
fuzz: improve coverage
2024-01-10 23:07:00 +01:00
Philippe Antoine
bb58abd4e0
fuzz: improve coverage
2024-01-10 22:06:37 +01:00
Sebastian Pipping
be47f6d5e8
Merge pull request #796 from libexpat/ci-control-flow-integrity
...
Make CI cover Clang's Control Flow Integrity sanitizer
2023-12-19 18:39:44 +01:00
Sebastian Pipping
64912b70fb
Merge pull request #795 from libexpat/autotools-install-shipped-xmlwf-manpage
...
Autotools: Make installation of shipped `doc/xmlwf.1` independent of docbook2man availability
2023-12-19 18:38:44 +01:00
Sebastian Pipping
18b44c980e
linux.yml: Cover Clang's Control Flow Integrity sanitizer
2023-12-19 01:31:10 +01:00
Sebastian Pipping
9495cefd94
qa.sh: Fix dropping of QA_SANITIZER
2023-12-19 01:31:10 +01:00
Sebastian Pipping
4b878938bb
qa.sh: Support Clang's Control Flow Integrity sanitizer
...
https://clang.llvm.org/docs/ControlFlowIntegrity.html
2023-12-19 01:31:10 +01:00
Sebastian Pipping
7384c88f9a
configure.ac: Make installation of shipped doc/xmlwf.1 independent of docbook2man availability
2023-12-18 23:59:25 +01:00
Sebastian Pipping
822d1706b2
Merge pull request #794 from libexpat/dependabot/github_actions/actions/upload-artifact-4.0.0
...
Actions(deps): Bump actions/upload-artifact from 3.1.3 to 4.0.0
2023-12-18 17:48:34 +01:00
dependabot[bot]
8c87ca470d
Actions(deps): Bump actions/upload-artifact from 3.1.3 to 4.0.0
...
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact ) from 3.1.3 to 4.0.0.
- [Release notes](https://github.com/actions/upload-artifact/releases )
- [Commits](a8a3f3ad30...c7d193f32e
)
---
updated-dependencies:
- dependency-name: actions/upload-artifact
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com>
2023-12-18 12:12:08 +00:00
Sebastian Pipping
b9fcca0aaa
Merge pull request #793 from libexpat/fix-bug-report-target
...
CMake|Autotools: Fix `PACKAGE_BUGREPORT` variable to something working
2023-12-17 23:09:46 +01:00
Sebastian Pipping
5a3c419e6a
CMake|Autotools: Fix PACKAGE_BUGREPORT variable to something working
2023-12-17 03:34:27 +01:00
Sebastian Pipping
85ee77d31f
Merge pull request #792 from libexpat/autotools-sync-cmake-files
...
autotools: Sync CMake templates with CMake 3.26
2023-12-16 16:50:45 +01:00
Sebastian Pipping
141cdab714
autotools: Sync CMake templates with CMake 3.26
2023-12-15 05:02:23 +01:00
Sebastian Pipping
fb702e6c0e
Merge pull request #790 from libexpat/cmake-build-benchmark-also
...
CMake: Build `tests/benchmark/benchmark.c` for `EXPAT_BUILD_TESTS`
2023-11-22 13:04:23 +01:00
Sebastian Pipping
a55b7925b2
benchmark.c: Address MSVC warnings C4267 and C4244
...
Compiler output was:
> tests\benchmark\benchmark.c(102): warning C4267: '=': conversion from 'size_t' to 'int', possible loss of data
> tests\benchmark\benchmark.c(117): warning C4244: 'initializing': conversion from '__int64' to 'int', possible loss of data
2023-11-21 21:42:50 +01:00
Sebastian Pipping
038040447e
CMake: Build tests/benchmark/benchmark.c for EXPAT_BUILD_TESTS
...
.. like the Autotools build system does.
2023-11-21 20:27:24 +01:00
Sebastian Pipping
3588720613
Merge pull request #787 from libexpat/tests-more-chunk-size-coverage
...
tests: Migrate more tests to variable chunk size parsing
2023-11-13 15:21:37 +01:00
Sebastian Pipping
d2b31760cd
tests: Simplify _XML_Parse_SINGLE_BYTES
...
Co-authored-by: Snild Dolkow <snild@sony.com>
2023-11-11 02:15:44 +01:00
Sebastian Pipping
3e5f6d6601
tests: Migrate more tests to variable chunk size parsing
2023-11-09 20:27:20 +01:00
Sebastian Pipping
795cf99922
tests: Make _XML_Parse_SINGLE_BYTES deny use with pathological input
2023-11-09 20:26:38 +01:00
Sebastian Pipping
df1e3d6f1e
Merge pull request #788 from SonyMobile/narrower-mingw-workaround
...
tests: Narrow test_buffer_can_grow_to_max mingw allocation workaround at compile time
2023-11-09 15:50:38 +01:00
Snild Dolkow
dcbc143680
tests: Narrow test_buffer_can_grow_to_max mingw allocation workaround
...
Instead of applying it to all less-than-64-bit platforms, let's narrow
the workaround to just the known failure: 32-bit mingw.
2023-11-09 10:46:51 +01:00
Sebastian Pipping
3a0c5d6ae5
Merge pull request #777 from libexpat/xml-dtd-undefined
...
Fix issues for compilation with XML_DTD undefined
2023-11-08 14:05:03 +01:00
Sebastian Pipping
d11ed9fa48
Merge pull request #786 from libexpat/tests-nan-and-infinity
...
tests: Use NAN and INFINITY of C99 and C++11
2023-11-07 16:37:38 +01:00
Sebastian Pipping
9411ac625b
tests: Use NAN and INFINITY of C99 and C++11
...
Effectively reverts commit f6f5d9bb4c
.
2023-11-07 14:22:31 +01:00
Sebastian Pipping
8a6c61de4a
lib: Add XML_GE to XML_GetFeatureList and XML_FeatureEnum
...
Co-authored-by: Snild Dolkow <snild@sony.com>
2023-11-07 13:00:42 +01:00
clang-format
ac14808b26
Mass-apply clang-format 17.0.3 using ./apply-clang-format.sh
2023-11-07 13:00:42 +01:00
Sebastian Pipping
55fecd6aa4
Drop redundant "XML_GE == 1" guards
...
These are redundant because further out there is a guard
for "XML_GE == 1" already. In the visual world, the pattern
is this:
> #if XML_GE == 1
> [..]
> # if XML_GE == 1
> [..]
> # endif
> [..]
> #endif
Spotted by Snild Dolkow, thanks!
Co-authored-by: Snild Dolkow <snild@sony.com>
2023-11-07 13:00:42 +01:00
Sebastian Pipping
caa2719863
Simplify "defined(XML_DTD) || XML_GE == 1" to "XML_GE == 1"
2023-11-07 13:00:42 +01:00
Sebastian Pipping
2848dc4e70
Simplify "! defined(XML_DTD) && XML_GE == 0" to "XML_GE == 0"
2023-11-07 13:00:42 +01:00
Sebastian Pipping
e3aaa06cdf
linux.yml: Add a dedicated run for -DEXPAT_GE=OFF
2023-11-07 13:00:42 +01:00