Age | Commit message (Collapse) | Author | Files | Lines | |
---|---|---|---|---|---|
2022-11-04 | Removed the unsafe nxt_memcmp() wrapper for memcmp(3). | Alejandro Colomar | 1 | -3/+3 | |
The casts are unnecessary, since memcmp(3)'s arguments are 'void *'. It might have been necessary in the times of K&R, where 'void *' didn't exist. Nowadays, it's unnecessary, and _very_ unsafe, since casts can hide all classes of bugs by silencing most compiler warnings. The changes from nxt_memcmp() to memcmp(3) were scripted: $ find src/ -type f \ | grep '\.[ch]$' \ | xargs sed -i 's/nxt_memcmp/memcmp/' Reviewed-by: Andrew Clayton <a.clayton@nginx.com> Signed-off-by: Alejandro Colomar <alx@nginx.com> | |||||
2022-08-29 | Implemented basic statistics API. | Valentin Bartenev | 1 | -0/+14 | |
2022-06-22 | Constified numerous function parameters. | Andrew Clayton | 1 | -5/+5 | |
As was pointed out by the cppcheck[0] static code analysis utility we can mark numerous function parameters as 'const'. This acts as a hint to the compiler about our intentions and the compiler will tell us when we deviate from them. [0]: https://cppcheck.sourceforge.io/ | |||||
2022-04-26 | Added new array APIs that also work with non-arrays. | Alejandro Colomar | 1 | -0/+26 | |
Similar to how C pointers to variables can always be considered as pointers to the first element of an array of size 1 (see the following code for an example of how they are equivalent), treating non-NXT_CONF_VALUE_ARRAY as if they were NXT_CONF_VALUE_ARRAYs of size 1 allows for simpler and more generic code. void foo(ptrdiff_t sz, int arr[sz]) { for (ptrdiff_t i = 0; i < sz; i++) arr[i] = 0; } void bar(void) { int x; int y[1]; foo(1, &x); foo(1, y); } nxt_conf_array_elements_count_or_1(): Similar to nxt_conf_array_elements_count(). Return a size of 1 when input is non-array, instead of causing undefined behavior. That value (1) makes sense because it will be used as the limiter of a loop that loops over the array and calls nxt_conf_get_array_element_or_itself(), which will return a correct element for such loops. nxt_conf_get_array_element_or_itself(): Similar to nxt_conf_get_array_element(). Return the input pointer unmodified (i.e., a pointer to the unique element of a hypothetical array), instead of returning NULL, which wasn't very useful. nxt_conf_array_qsort(): Since it's a no-op for non-arrays, this API can be reused. | |||||
2022-04-26 | Added 'const' for read-only function parameter. | Alejandro Colomar | 1 | -1/+2 | |
That parameter is not being modified in the function. Make it 'const' to allow passing 'static const' variables. | |||||
2020-04-01 | Fixed build with Clang 10, broken by 32578e837322. | Valentin Bartenev | 1 | -1/+3 | |
This silences the -Wimplicit-int-float-conversion warning. | |||||
2020-03-30 | Configuration: support for rational numbers. | Valentin Bartenev | 1 | -158/+99 | |
2020-03-25 | Configuration: fixed comments parsing. | Valentin Bartenev | 1 | -1/+5 | |
Unclosed multi-line comments and "/" at the end of JSON shouldn't be allowed. | |||||
2020-02-20 | Configuration: stripping comments from the input JSON. | Valentin Bartenev | 1 | -6/+66 | |
This allows to have JavaScript-like comments in the uploading JSON. | |||||
2019-10-11 | Fixed passing false in namespace flags. | Tiago Natel | 1 | -0/+7 | |
This patch closes #328 in github. | |||||
2019-09-18 | Configuration: added ability to modify object members with slashes. | Valentin Bartenev | 1 | -39/+49 | |
Example: PUT/POST/DELETE /config/listeners/unix:%2Fpath%2Fto%2Fsocket This follows a49ee872e83d. | |||||
2019-09-16 | Configuration: added ability to access object members with slashes. | Valentin Bartenev | 1 | -0/+15 | |
Now URI encoding can be used to escape "/" in the request path: GET /config/listeners/unix:%2Fpath%2Fto%2Fsocket/ | |||||
2019-04-24 | Configuration: support for POST operations on arrays. | Valentin Bartenev | 1 | -11/+36 | |
It allows to add an array element without specifying the index. | |||||
2019-04-24 | Configuration: support for manipulations of array elements. | Valentin Bartenev | 1 | -29/+141 | |
Now PUT and DELETE operations also work on elements. This closes #242 issue on GitHub. | |||||
2019-04-24 | Refactored nxt_conf_op_compile(). | Valentin Bartenev | 1 | -7/+8 | |
Now index is always initialized for create operations. The changes in nxt_conf_op_compile() simplify adding upcoming support of operations with arrays. No functional changes. | |||||
2019-04-24 | Removed unused field from nxt_conf_op_s. | Valentin Bartenev | 1 | -2/+1 | |
2019-02-26 | Introduced nxt_conf_array_qsort(). | Igor Sysoev | 1 | -0/+16 | |
2019-02-26 | Introduced nxt_conf_array_elements_count(). | Igor Sysoev | 1 | -0/+7 | |
2018-11-15 | Fixed discovering of modules on 64-bit big-endian systems. | Valentin Bartenev | 1 | -1/+1 | |
The nxt_conf_map_object() function used nxt_int_t for NXT_CONF_MAP_INT, which was 8 bytes long on 64-bit systems. But the nxt_port_main_start_worker_handler() used it to map into the int field of the nxt_common_app_conf_t structure, which was 4 bytes. As the result, on a 64-bit big-endian system all the meaningful module type numbers were assigned into the gap above the "type" field. The bug was discovered on IBM/S390x. | |||||
2018-09-20 | Controller: addressing of array elements in requests. | Valentin Bartenev | 1 | -1/+20 | |
2018-09-20 | Controller: certificates storage interface. | Valentin Bartenev | 1 | -0/+99 | |
2018-09-20 | Deduplicated string value initializations. | Valentin Bartenev | 1 | -64/+22 | |
2018-06-25 | Introduced nxt_length() macro. | Valentin Bartenev | 1 | -4/+4 | |
2018-04-04 | Style: capitalized letters in hexadecimal literals. | Valentin Bartenev | 1 | -7/+7 | |
2018-03-29 | nxt_lvlhsh_each() refactoring and nxt_lvlhsh_each_init(). | Igor Sysoev | 1 | -2/+1 | |
2018-01-29 | Introducing extended app process management. | Max Romanov | 1 | -0/+7 | |
- Pre-fork 'processes.spare' application processes; - fork more processes to keep 'processes.spare' idle processes; - fork on-demand up to 'processes.max' count; - scale down idle application processes above 'processes.spare' after 'processes.idle_timeout'; - number of concurrently started application processes also limited by 'processes.spare' (or 1, if spare is 0). | |||||
2017-11-21 | Fixed crash on invalid JSON number. | Valentin Bartenev | 1 | -0/+4 | |
2017-09-15 | Introducing application timeout. | Max Romanov | 1 | -1/+1 | |
2017-09-12 | Fixed error messages grammar. | Nick Shadrin | 1 | -49/+48 | |
2017-08-16 | Introduced nxt_conf_get_array_element(). | Valentin Bartenev | 1 | -0/+19 | |
2017-08-16 | Object mapping interface extended with more string types. | Valentin Bartenev | 1 | -6/+41 | |
2017-08-15 | Fixed building on ppc. | Valentin Bartenev | 1 | -1/+1 | |
2017-08-11 | Controller: more HTTP headers and detailed JSON parsing errors. | Valentin Bartenev | 1 | -37/+320 | |
2017-08-11 | Fixed parsing of JSON encoded UTF-16 surrogate pairs. | Valentin Bartenev | 1 | -16/+13 | |
2017-08-08 | Fixed JSON escape sequence parsing. | Valentin Bartenev | 1 | -2/+4 | |
2017-08-02 | Using old-style packed attribute specification for compatibility. | Max Romanov | 1 | -4/+4 | |
2017-07-25 | Fixed building on Solaris by Sun C. | Max Romanov | 1 | -2/+2 | |
2017-07-18 | Configuration: improved declaration of short strings. | Valentin Bartenev | 1 | -10/+14 | |
2017-07-18 | Configuration: reduced memory consumption of long strings. | Valentin Bartenev | 1 | -24/+33 | |
2017-07-18 | Configuration: reduced memory consumption. | Valentin Bartenev | 1 | -4/+4 | |
2017-07-10 | Configuration: nxt_conf_map_object() improvements. | Valentin Bartenev | 1 | -14/+9 | |
2017-07-07 | Controller: relaxed JSON parser. | Valentin Bartenev | 1 | -80/+72 | |
Now it allows commas after the last elements in objects and arrays, as it's a common Igor's mistake. | |||||
2017-07-06 | Controller: sending JSON configuration to router. | Valentin Bartenev | 1 | -1/+65 | |
2017-07-06 | Fixed mapping of int32_t in nxt_conf_map_object(). | Valentin Bartenev | 1 | -1/+1 | |
2017-07-05 | Configuration: basic validation of schema. | Valentin Bartenev | 1 | -51/+85 | |
2017-06-29 | Added nxt_msec_t element to nxt_conf_map_object(). | Igor Sysoev | 1 | -9/+15 | |
2017-06-28 | Configuration: reduced names of structures, functions, and macros. | Valentin Bartenev | 1 | -0/+1882 | |