Eric Haszlakiewicz
22773b1e51
Fix the expected output for test_set_serializer.
2022-07-24 19:00:27 +00:00
Eric Haszlakiewicz
16208fc01a
Add test to check for the memory leak mentioned in issue #781
2022-07-24 18:59:26 +00:00
Eric Hawicz
2a2d861bc0
Merge pull request #781 from dddaniel/master
...
Fix memory leak with emtpy strings in json_object_set_string
2022-07-24 14:15:42 -04:00
Eric Haszlakiewicz
d28ac67dde
Fix issue #775 - use a loop instead of list(TRANSFORM ...) to support cmake < 3.12.
2022-06-27 02:15:24 +00:00
Eric Hawicz
5d98f7825a
Merge pull request #776 from stoeckmann/typo
...
Fix typo
2022-06-21 21:39:00 -04:00
Eric Haszlakiewicz
6ee0a35a20
Fix #771/#768 by marking usage() as "noreturn" instead of using "FALLTHRU" in the case statement where it'd called.
2022-06-13 01:02:53 +00:00
Eric Hawicz
11546bfd07
Merge pull request #769 from An7ar35/issue-768
...
Issue #768
2022-06-03 23:14:16 -04:00
Eric Haszlakiewicz
49c3721a5a
Unset NDEBUG so assert() is enabled in all tests. One more fix there when building with -DCMAKE_BUILD_TYPE=release.
2022-05-30 15:39:54 +00:00
Eric Haszlakiewicz
2f0942bdd7
Specify dependent libraries, including -lbsd, in a more consistent way so linking against a static json-c works better. Related issue #766
...
Use target_link_libraries, plus fill in Libs.private in json-c.pc so pkg-config --static --libs works appropriately.
Also, only link against libbsd when arc4random is actually found there.
2022-05-30 15:30:11 +00:00
Eric Haszlakiewicz
6ba1adf8ef
Include the tests and apps directories at the _end_, since order in the
...
cmake rules matters, and fix compile warnings now that we're building
those sources with all the regular flags.
2022-05-30 14:33:16 +00:00
Eric Haszlakiewicz
86b46cac07
Add --disable-static and --disable-dynamic options to the cmake-configure script.
2022-05-30 14:31:08 +00:00
Eric Haszlakiewicz
f2fc1ca00a
Note the DSIABLE_JSON_POINTER and DISABLE_EXTRA_LIBS build options on the README
2022-04-14 12:57:43 +00:00
Eric Haszlakiewicz
acccefd770
Add a "Getting Help" section to the README.
2022-04-14 12:55:32 +00:00
Eric Haszlakiewicz
de5a64888a
Update the master branch to version 16.99
2022-04-14 12:29:39 +00:00
Eric Haszlakiewicz
7e3eba72db
Clarify how to set the uploaded release tarballs to be publically readable.
2022-04-14 12:17:59 +00:00
Eric Haszlakiewicz
7d303478a4
Update the ChangeLog with recent changes, in preparation for a 0.16 release.
...
Add a list of issues closed for this release.
2022-04-14 01:05:38 +00:00
Eric Haszlakiewicz
66dcdf549e
Add new authors since the 0.15 release, tweak instructions for how to update that list.
2022-04-14 01:04:53 +00:00
Eric Hawicz
4902f9cb87
Merge pull request #765 from jvoisin/patch-1
...
Improve a bit the coverage of the fuzzer
2022-04-13 14:28:51 -04:00
Eric Haszlakiewicz
46b58ad9e7
Fix issue #764 : adjust test_util_file to match new output (changed in 6e53347)
2022-04-08 22:58:24 +00:00
Eric Hawicz
0b937f6173
Merge pull request #758 from c3h2-ctf/context
...
Preserve context if out of memory
2022-04-04 18:01:39 -04:00
Eric Hawicz
65274cf3b5
Update issue templates
2022-04-04 17:10:31 -04:00
Eric Haszlakiewicz
e244146dfd
Remove single quote from #error line. Fixes issue #761
2022-03-25 01:12:07 +00:00
Eric Hawicz
a1c092bd7b
Merge pull request #760 from BonsaiYi/error
...
Code style: removed unneeded double-quotes
2022-03-23 00:14:36 -04:00
Eric Hawicz
79459b2de2
Merge pull request #755 from c3h2-ctf/error
...
Fix error messages
2022-03-19 10:05:48 -04:00
Eric Hawicz
2326e34390
Merge pull request #754 from c3h2-ctf/doc
...
Minor improvements to documentation
2022-03-19 10:04:58 -04:00
Eric Hawicz
f0d93cee14
Merge pull request #748 from c3h2-ctf/printbuf
...
sprintbuf(): test for all vsnprintf error values
2022-03-07 00:06:57 -05:00
Eric Hawicz
9b832c8710
Merge pull request #752 from c3h2-ctf/typos
...
Fix typos
2022-03-06 23:33:42 -05:00
Eric Hawicz
a4389f4f30
Merge pull request #749 from c3h2-ctf/sprintbuf
...
sprintbuf(): handle printbuf_memappend errors
2022-03-03 21:32:09 -05:00
Eric Hawicz
4493db76d6
Merge pull request #750 from c3h2-ctf/clearmem
...
printbuf_memset(): set gaps to zero
2022-03-03 21:29:27 -05:00
Eric Hawicz
1491d92038
Merge pull request #751 from c3h2-ctf/arguments
...
printbuf: do not allow invalid arguments
2022-03-03 21:26:22 -05:00
Eric Hawicz
bd56cc8bf7
Merge pull request #745 from c3h2-ctf/vasprintf
...
vasprintf(): avoid out of memory accesses
2022-02-27 08:34:21 -05:00
Eric Hawicz
723ac8cbb5
Merge pull request #746 from rouault/typo_fixes
...
Fix typos in code comments and ChangeLog
2022-02-26 23:45:15 -05:00
Eric Hawicz
66cce0a1d7
Merge pull request #739 from rouault/avoid_unsigned_integer_overflow
...
json_escape_str(): avoid harmless unsigned integer overflow
2022-02-18 20:21:18 -05:00
Eric Hawicz
b11f79c52c
Merge pull request #741 from rouault/json_type_to_name_formatter
...
json_type_to_name(): use correct printf() formatter
2022-02-18 20:08:31 -05:00
Eric Hawicz
78246db72f
Merge pull request #742 from rouault/json_object_copy_serializer_data_add_assertion
...
json_object_copy_serializer_data(): add assertion
2022-02-18 20:08:02 -05:00
Eric Hawicz
a1ea216878
Merge pull request #744 from Kizuna-Meraki/close-random
...
Close file on error path.
2022-02-18 20:07:33 -05:00
Eric Hawicz
3b4f1e92ad
Merge pull request #737 from tniessen/patch-1
...
Fix typo in README
2022-01-11 21:25:38 -05:00
Eric Haszlakiewicz
a5c2e11460
Cause the cmake include dirs to also have ${CMAKE_INSTALL_INCLUDEDIR}/json-c, so downstream packages that use cmake to link against json-c can choose whether to include headers as just e.g. #include <json_object.h>, if they care to do so.
...
Update the README to better explain this, and make a few other tweaks.
2021-12-22 02:52:37 +00:00
Eric Haszlakiewicz
2d2382d709
Add linkhash accessor functions (lh_table_head(), lh_entry_next(), etc...) to pave the way for making the lh_table and lh_entry structure opaque in the future.
...
Update the docs to mark all members of those structures deprecated, and
suggest what to use instead.
2021-11-30 03:27:55 +00:00
Eric Haszlakiewicz
320548caf6
Drop the REFCOUNT_DEBUG code, it hasn't been used in ages.
2021-11-30 03:08:02 +00:00
Eric Hawicz
9a90b8477b
Merge pull request #734 from json-c/newer-appveyor
...
Newer appveyor config for VS2022 etc...
Update the appveyor config to specify "image" instead of just "os", and build for VS2017, VS2019 and VS2022.
2021-11-29 13:40:41 -05:00
Eric Haszlakiewicz
1cb56e705f
Put the most recent image first in appveyor builds.
2021-11-29 18:21:05 +00:00
Eric Haszlakiewicz
1763edaba3
Skip most "Release" builds. s/b_config/CONFIGURATION/ to fix artifact creation.
2021-11-29 18:18:48 +00:00
Eric Haszlakiewicz
a5fed59756
There doesn't seem to be a way to extend the appveyor build matrix for just one image, so instead list a whole bunch of excluded builds.
2021-11-27 02:55:29 +00:00
Eric Haszlakiewicz
0910e18bbd
Use the newer appveyor images to build for VS2017 and VS2019. Trim the number of builds we do.
2021-11-27 02:29:26 +00:00
Eric Haszlakiewicz
f1fb9abf14
Note the need to also set CTEST_OUTPUT_ON_FAILURE to get test output
2021-11-26 22:49:42 +00:00
Eric Hawicz
42aa6f7257
Merge pull request #732 from DiracResearch/fix/static_include_dirs
...
Fix/static include dirs
2021-11-11 23:52:43 -05:00
Eric Hawicz
9b0fb2b33e
Merge pull request #727 from jobol/propo2
...
Really use prefix JSON_C_OBJECT_ADD_
2021-10-22 19:06:11 -04:00
Eric Hawicz
05c5d15075
Merge pull request #729 from DeX77/patch-1
...
* don't assume includedir
2021-10-17 14:23:28 -04:00
Eric Hawicz
382f9462c2
Merge pull request #726 from leongross/fix/test-cmake3.1
...
fix cmake version for tests
2021-10-09 09:17:25 -04:00
Eric Hawicz
4fc44f32df
Merge pull request #722 from imaami/fix-json_tokener_new_ex-use-after-free
...
Fix use-after-free in json_tokener_new_ex()
2021-09-04 23:16:13 -04:00
Eric Hawicz
dc1ef7d566
Merge pull request #718 from Pawday/master
...
CMake create uninstall target if unix generator is used
2021-07-31 22:46:01 -04:00
Eric Haszlakiewicz
f61f1a7a91
Add workaround for Visual Studio not knowing about "inline".
2021-07-25 20:31:59 +00:00
Eric Haszlakiewicz
db6a6cc2b2
Switch the Travis build to use osx_image: xcode12.5, in an attempt to avoid timeouts with Homebrew.
2021-07-25 20:03:55 +00:00
Eric Haszlakiewicz
6a0df2609e
Merge some old work to include (some of) PR #464 into the current master branch.
2021-07-25 19:07:06 +00:00
Eric Haszlakiewicz
8c727e5ce1
Only define an "uninstall" target if it's not already defined (e.g. by projects that include json-c)
2021-07-25 15:11:11 +00:00
Eric Hawicz
be9671e48a
Merge pull request #714 from Hex052/clang-format_AfterCaseLabel
...
Add AfterCaseLabel to .clang-format
2021-07-05 18:18:06 -04:00
Eric Haszlakiewicz
75bf657cc2
If inttypes.h is present, use it, even on Windows.
2021-06-13 21:12:22 +00:00
Eric Haszlakiewicz
9ca50cf2f8
Issue #709 : adjust some include guards to be a bit more json-c specific.
2021-06-02 23:53:23 +00:00
Eric Hawicz
0b7e78c309
Merge pull request #706 from davidjmccann/master
...
Check __STDC_VERSION__ is defined before checking its value
2021-05-15 08:41:24 -04:00
Eric Hawicz
cd7109f767
Merge pull request #696 from ssrlive/master
...
To avoid target exe file export JSON functions.
2021-05-01 15:21:31 -04:00
Eric Hawicz
78e390a261
Merge pull request #701 from commodo/configurable-opts
...
[RFC] json_pointer: allow the feature to be disabled
2021-04-17 17:26:49 -04:00
Eric Hawicz
94909840be
Merge pull request #700 from Philosoph228/werror-fix
...
Fix unused variable for Win32 build in random_seed.c
2021-04-14 22:38:36 -04:00
Eric Haszlakiewicz
041cef434a
Add a DISABLE_EXTRA_LIBS option to skip using libbsd, per @neheb's request on issue #692/commit 0f61f692.
2021-02-15 20:19:56 +00:00
Eric Haszlakiewicz
f787810890
If arc4random is used, don't bother compiling in the other fallback methods since they'll never be used. Fixes PR#695 about unreachable code too.
2021-02-13 03:23:58 +00:00
Eric Hawicz
7c859c54e4
Merge pull request #694 from ihsinme/patch-1
...
fix invalid unsigned arithmetic.
2021-02-06 17:25:24 -05:00
Eric Haszlakiewicz
0f61f6921b
Iesue #692 : use arc4random() if it's available (in libc on BSD systems, and libbsd on Linux).
2021-01-13 01:57:25 +00:00
Eric Haszlakiewicz
69d650528d
Keep the doc directory in the nodoc release tarball, just exclude its contents.
2021-01-13 01:30:16 +00:00
Eric Hawicz
4754f47434
Merge pull request #674 from ploxiln/random_seed_err_continue
...
random_seed: on error, continue to next method
2021-01-12 20:22:54 -05:00
Eric Hawicz
1fcb9e476b
Merge pull request #689 from neheb/patch-1
...
fix compilation with clang
2020-12-18 21:30:14 -05:00
Eric Hawicz
df27756491
Merge pull request #667 from stoeckmann/regression
...
Fixed test1 regression.
2020-09-11 20:56:51 -04:00
Eric Hawicz
785a94b7a2
Merge pull request #665 from stoeckmann/tokener
...
Handle more allocation failures in json_tokener* functions
2020-08-24 09:51:41 -04:00
Eric Hawicz
eb08a92218
Merge pull request #660 from stoeckmann/arraylist
...
Validate size arguments in arraylist functions.
2020-08-24 09:51:18 -04:00
Eric Hawicz
b4e72c2655
Merge pull request #664 from stoeckmann/string
...
Limit strings at INT_MAX length
2020-08-23 16:43:31 -04:00
Eric Hawicz
f941931804
Merge pull request #663 from stoeckmann/strerror
...
Properly format errnos in _json_c_strerror
2020-08-23 16:38:21 -04:00
Eric Hawicz
1bc7a6b223
Merge pull request #662 from stoeckmann/random
...
Prevent signed overflow in get_time_seed
2020-08-23 16:34:40 -04:00
Eric Haszlakiewicz
2b439ea598
Fix json_object_get_boolean() doc for the object and array cases (always returns 0), and add those cases to the test_cast test.
...
See also issue #658 .
2020-08-17 14:57:21 +00:00
Eric Hawicz
cf30cba4ac
Merge pull request #657 from stoeckmann/getrandom
...
Use GRND_NONBLOCK with getrandom.
2020-08-15 15:01:41 -04:00
Eric Hawicz
104b408ee8
Merge pull request #656 from pogaram/fix-warnings
...
Fixed warnings
2020-08-14 16:57:32 -04:00
Eric Hawicz
98b7ee93fd
Merge pull request #655 from MarcT512/issue654
...
json_parse: Fix read past end of buffer
2020-08-07 10:18:30 -04:00
Eric Haszlakiewicz
8c7849e6e3
Eliminate use of ctype.h and replace isdigit() and tolower() with non-locale-sensitive approaches.
2020-08-02 04:06:44 +00:00
Eric Haszlakiewicz
f3d8006d34
Neither vertical tab nor formfeed are considered whitespace per the JSON spec, remove them from is_ws_char().
2020-08-02 03:59:56 +00:00
Eric Haszlakiewicz
8b43ff0c22
Merge the is_ws_char() and is_hex_char() changes to json_tokener from branch 'ramiropolla/for_upstream' (PR #464 )
2020-08-02 02:55:45 +00:00
Eric Haszlakiewicz
bfec9c8685
Take a hint from PR #464 and use json_object_new_string_len() to avoid a needless extra strlen() call.
...
Also, create a _json_object_get_string_len() for internal use when we know
for sure the object we're dealing with is a json_type_string.
2020-08-02 02:23:01 +00:00
Eric Hawicz
56a89f902f
Merge pull request #653 from lamby/966657-json-c-please-make-the-build-reproducible
...
Make the documentation build reproducibly
2020-08-01 22:06:38 -04:00
Eric Hawicz
88cce7b9c5
Merge pull request #651 from alanc/getrandom
...
Getrandom
2020-07-31 20:30:11 -04:00
Eric Haszlakiewicz
002411293d
Issue #649 : Drop the generated doc/Doxyfile when creating a release.
2020-07-28 03:52:22 +00:00
Eric Hawicz
66f8ca3c03
Merge pull request #650 from sartura/readme-update
...
README: fix spelling errors
2020-07-27 10:31:05 -04:00
Eric Haszlakiewicz
47189b5ff1
Include updating the json-c-current-releaes gh-pages symlink as part of the release process.
2020-07-26 15:51:07 +00:00
Eric Haszlakiewicz
de02d09c32
Update the master branch to version 0.15.99
2020-07-26 15:26:53 +00:00
Eric Haszlakiewicz
870965e1ea
Update AUTHORS, add issues_closed_for_0.15.md, tweak the release checklist slightly.
2020-07-24 03:17:13 +00:00
Eric Hawicz
616b1050b2
Merge pull request #648 from MarcT512/rbf
...
Fix "may be used uninitialized" Release build failure
2020-07-23 22:26:58 -04:00
Eric Haszlakiewicz
730e3d044f
Issue #594 - provide an OVERRIDE_GET_RANDOM_SEED cmake variable to override json_c_get_random_seed() for embedded platforms where time(NULL) doesn't work.
...
Example:
mkdir build && cd build
cmake -DOVERRIDE_GET_RANDOM_SEED='do { extern uint32_t getMsTicks(void); int ms = getMsTicks() * 433494437; return ms; } while(0)' ..
2020-07-22 02:25:03 +00:00
Eric Hawicz
64de4b6e9f
Merge pull request #646 from pascal-cuoq/fix_645
...
Cast to unsigned char instead of int when calling tolower (Fixes #645 )
2020-07-21 21:24:59 -04:00
Eric Haszlakiewicz
024e835f4c
Update the ChangeLog with recent changes, in preparation for a 0.15 release.
2020-07-20 03:39:01 +00:00
Eric Haszlakiewicz
78a0f2ea5d
Remove the obsolete config.h.win32
2020-07-17 03:47:28 +00:00
Eric Haszlakiewicz
e46b9cdb7d
Fix a number of things with the generated docs, including translating triple-backtick code blocks into a form doxygen understands.
2020-07-17 03:46:21 +00:00
Eric Haszlakiewicz
9a7de35b92
Add some more detail about how to use json-c in README.md.
2020-07-17 03:42:38 +00:00
Eric Haszlakiewicz
cb10a13e94
Remove the THIS_FUNCTION_IS_DEPRECATED define, we stopped using it long ago.
2020-07-17 03:20:29 +00:00
Eric Haszlakiewicz
2508109b18
Remove the obsolete README.json_object-split.md, and mark README.md as being the doxygen mainpage.
2020-07-12 19:16:19 +00:00