C utility functions for OpenWRT libraries
Find a file
Sergiy Kibrik 136a519626 ulog: avoid accidental /dev/kmsg creation
Race is possible in ulog_kmsg(): if no /dev/kmsg exists
(e.g. while /dev gets re-mounted) regular file created instead.
>From this point system goes without kernel logger:
special character file can't be created anymore, all clients keep
overwriting single message in regular file.

To avoid this we open file in "r+" mode which doesn't create
file if it's not found.

Signed-off-by: Sergiy Kibrik <sakib@meta.ua>
Cc: John Crispin <blogic@openwrt.org>
2015-09-15 07:29:59 +02:00
examples libubox: cmake: Add BUILD_EXAMPLES option 2015-06-14 15:25:38 +02:00
lua lua: do not hardcode /opt/local/include for Apple. 2014-12-11 17:57:07 +01:00
sh Revert "jshn: only keep UP_* variables around while they are needed" 2014-11-23 23:53:44 +01:00
.gitignore add a cmake file for the examples and add the binaries to .gitignore 2012-10-21 23:01:30 +02:00
avl-cmp.c add avl_strcmp 2012-05-26 18:01:18 +02:00
avl-cmp.h add avl_strcmp 2012-05-26 18:01:18 +02:00
avl.c list_compat.h: remove 2014-03-20 23:06:42 +01:00
avl.h avl: add AVL_TREE macro to define an initialized struct avl_tree 2014-03-27 17:39:53 +01:00
base64.c b64_encode(): fixed input[] not initialized warn under gcc 4.4.5 2015-09-09 11:03:07 +02:00
blob.c blob: improve out-of-memory handling 2014-07-26 03:50:50 +02:00
blob.h blob: improve out-of-memory handling 2014-07-26 03:50:50 +02:00
blobmsg.c blobmsg: remove unneeded assignment in blobmsg_alloc_string_buffer(). 2014-12-11 17:58:29 +01:00
blobmsg.h blobmsg: accept NULL attr in blobmsg_get_string() 2014-08-03 15:00:54 +02:00
blobmsg_json.c blobmsg_json: include json.h inside blobmsg_json.c instead of the public header file 2014-09-23 12:03:32 +02:00
blobmsg_json.h blobmsg_json: avoid redefinition of json_object 2014-10-24 13:40:14 +02:00
CMakeLists.txt Build static version of libblobmsg_json 2015-09-09 11:02:49 +02:00
jshn.c jshn: add error handling and fix memory leak in jshn_format(). 2014-12-11 17:58:42 +01:00
json_script.c json_script: fix logic invert of handle_expr_not(). 2014-12-22 15:46:21 +01:00
json_script.h json_script: add json_script_run_file() 2014-04-28 17:54:25 +02:00
kvlist.c kvlist: constify arguments 2014-04-28 17:56:08 +02:00
kvlist.h kvlist: constify arguments 2014-04-28 17:56:08 +02:00
list.h list.h: implement type safety for container_of() 2013-03-18 05:55:00 +01:00
md5.c md5: include utils.h instead of endian.h to fix portability issues 2015-06-29 16:13:08 +02:00
md5.h md5: add a new implementation under permissive license 2014-10-01 16:39:15 +02:00
runqueue.c libubox: runqueue: Cancel task timeout when completeing task 2014-01-29 03:32:30 +00:00
runqueue.h runqueue: add a function that allows adding jobs to the front of the runqueue 2013-11-18 12:25:21 +01:00
safe_list.c runqueue: add a function that allows adding jobs to the front of the runqueue 2013-11-18 12:25:21 +01:00
safe_list.h runqueue: add a function that allows adding jobs to the front of the runqueue 2013-11-18 12:25:21 +01:00
ulog.c ulog: avoid accidental /dev/kmsg creation 2015-09-15 07:29:59 +02:00
ulog.h ulog: introduce new simple logging api 2015-02-26 10:43:56 +01:00
uloop.c allow process callback to call uloop_end() 2015-03-21 05:50:23 +01:00
uloop.h uloop: Add flag to allow callback to be called on error conditions. 2014-02-23 18:18:32 +01:00
usock.c usock: set socket flags right after creating it 2015-01-15 13:10:58 +01:00
usock.h usock: add helper waiting for socket to be ready 2015-01-15 13:10:49 +01:00
ustream-fd.c ustream-fd: handle uloop errors 2015-07-14 16:57:05 +02:00
ustream.c ustream: tweak ustream_prepare_buf() a bit. 2015-06-14 15:15:43 +02:00
ustream.h ustream: add function ustream_read(). 2015-01-21 20:00:39 +01:00
utils.c utils: use clock_get_time() for clock_gettime() on Apple. 2015-01-21 20:11:30 +01:00
utils.h add a base64 implementation (based on FreeBSD code) 2015-05-08 14:34:29 +02:00
vlist.c vlist: constify key argument to vlist_add 2013-10-05 21:40:04 +02:00
vlist.h vlist: add static initializer macros 2014-06-05 15:28:45 +02:00