aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2009-09-04doc: Fix typoPetri Lehtinen1-3/+3
2009-09-04Add reference stealing functions for inserting values to objects and arraysPetri Lehtinen5-13/+101
The non-stealing functions are now just simple wrappers around these.
2009-09-02Change the version to 1.0+Petri Lehtinen2-2/+2
2009-08-25jansson 1.0v1.0Petri Lehtinen2-3/+4
2009-08-25Distribute appropriate filesPetri Lehtinen4-1/+12
2009-08-25test: Add Makefile.am to test/testprogsPetri Lehtinen3-3/+14
This way it's an individual subdirectory and things go easier.
2009-08-25Add some missing copyright noticesPetri Lehtinen2-0/+12
2009-08-24Detect garbage near EOF in json_loadf() and json_load_file()Petri Lehtinen2-0/+21
2009-08-24Add test for numbersPetri Lehtinen3-1/+46
2009-08-23Expand value test coveragePetri Lehtinen6-2/+256
2009-08-23array: Fix a few checks and a leakPetri Lehtinen1-2/+4
2009-08-23run-test: Don't remove all testlogs when starting a new test suitePetri Lehtinen1-2/+1
2009-08-13Add README and API referencePetri Lehtinen11-1/+788
2009-08-04Refuse to dump other types than array and object as the root valuePetri Lehtinen1-0/+6
2009-07-30Remove unimplemented json_clone()Petri Lehtinen1-2/+0
2009-07-30Add macro json_is_booleanPetri Lehtinen1-0/+1
2009-07-30Add LICENSE and a copyright note to all sourcesPetri Lehtinen18-0/+130
2009-07-28Rename json_{load,dump} to json_{load,dump}_filePetri Lehtinen7-41/+41
2009-07-28Fix some memory leaks and invalid memory referencesPetri Lehtinen3-7/+27
2009-07-28Enhance test systemPetri Lehtinen9-137/+170
- Tests are now named - Testlogs are preserved between runs - Tests can be run through Valgrind Memcheck tool
2009-07-26Expand encoder test coveragePetri Lehtinen2-1/+5
2009-07-26Expand parser and Unicode test coveragePetri Lehtinen7-17/+123
2009-07-16Implement support for \u escapesPetri Lehtinen5-13/+152
2009-07-16Show the whole UTF-8 sequence in error message, not just the first bytePetri Lehtinen1-1/+14
2009-07-16Remove TODOPetri Lehtinen1-18/+0
2009-07-14Report errors from lexical and stream level in parserPetri Lehtinen2-57/+93
Before, only the syntax level (parse_*) was able to set the error string. This patch fixes the situation so that lexical (lex_*) and stream (stream_*) levels can report detailed error messages. Also, instead of 0, EOF is now returned by stream on error.
2009-07-13Get rid of JSON_SORT_KEYS dump flagPetri Lehtinen1-1/+0
Object sorting will be implemented later.
2009-07-13Decode and check for correct UTF-8Petri Lehtinen6-4/+189
All strings (decoded JSON text, the argument of json_string(), the key argument of json_object_set()) are checked for valid UTF-8.
2009-07-13Streamify the loaderPetri Lehtinen4-133/+265
It's no longer needed to load the whole input into a string and then parse from the string. Instead, the input is read as needed from a string or file.
2009-07-13Get rid of json_dumpfd and json_loadfdPetri Lehtinen7-80/+1
fdopen() makes supporting separate API for file descriptors useless. Supporting fd's also makes Jansson less portable.
2009-07-13Little clean-up in parserPetri Lehtinen1-10/+15
Before, json_loads checked for '[' or '{' at the beginning. Now there's a dedicated function for that: parse_json(). Also rename parse() to parse_value().
2009-07-13Unify naming in parserPetri Lehtinen1-74/+73
No functional changes.
2009-07-13Make the lexer not depend on localePetri Lehtinen1-8/+12
... by not using isalpha() and isspace(). While at it, fix some other minor things.
2009-07-09Don't dump extra spaces when indentingPetri Lehtinen1-2/+1
2009-07-09Add some testsPetri Lehtinen15-1/+487
2009-07-09Fix dumping of Unicode control codesPetri Lehtinen1-13/+33
Inside strings, All UTF-8 characters except for \, " and Unicode control codes are dumped as-is. The control codes that have a special one-character escape use that escape, and other control codes are dumped using the \uXXXX escape.
2009-07-04Fix number tokenizerPetri Lehtinen1-7/+12
2009-07-04Fix empty array dumpingPetri Lehtinen1-1/+1
2009-07-04strbuffer: Optimize string terminationPetri Lehtinen2-6/+5
Do not zero all of the memory, just the first unused byte to make the string null terminated.
2009-07-04Separate integers and real numbersPetri Lehtinen4-32/+117
2009-06-30Use -WerrorPetri Lehtinen1-1/+1
2009-06-30Fix json_loadf and json_loadfd with empty inputPetri Lehtinen4-14/+22
Nothing was appended to strbuffer, so the buffer was left empty. An empty strbuffer is not an empty string but NULL, so the result was a segfault. This patch fixes the problem by initializing strbuffer to an empty string.
2009-06-30Print correct error message on premature end of arrayPetri Lehtinen1-14/+16
2009-06-15Fix json_set_errorPetri Lehtinen1-1/+4
Both error->line and error->text were set improperly, sigh.
2009-06-15Don't use AM_MAINTAINER_MODEPetri Lehtinen1-1/+0
2009-06-15Add TODOPetri Lehtinen1-0/+18
2009-06-15Fix a few memory leaks in json_parse_object()Petri Lehtinen1-1/+5
2009-06-15Implement json_load, json_loadf and json_loadfdPetri Lehtinen2-10/+114
2009-06-13strbuffer_value: Return a read-only pointer rather than duplicating the valuePetri Lehtinen3-4/+4
2009-06-13strbuffer: Allocate enough space for value initiallyPetri Lehtinen1-1/+1