summaryrefslogtreecommitdiff
path: root/src/libsystemd
AgeCommit message (Collapse)Author
2015-11-09Merge pull request #1820 from michich/errno-v2Daniel Mack
[v2] treewide: treatment of errno and other cleanups
2015-11-06doc: correct punctuation and improve typography in documentationJan Engelhardt
2015-11-05sd-resolve: simplify pthread_join() callMichal Schmidt
POSIX says: The pthread_join() function shall not return an error code of [EINTR].
2015-11-04Merge pull request #1768 from vcaputo/sd-daemon-listen-fds-overflow-bisLennart Poettering
sd-daemon: fix potential LISTEN_FDS overflow in sd_listen_fds()
2015-11-03sd-daemon: fix potential LISTEN_FDS overflow in sd_listen_fds()Vito Caputo
2015-11-03sd-daemon: explicitly filter out -1 when parsing watchdog timeoutLennart Poettering
We already filter out 0, and as -1 is usually special (meaning infinity, as in USEC_INFINITY) we should better not accept it either. Better safe than sorry...
2015-11-03parse-util: introduce parse_ifindex() and make use of it everywhereLennart Poettering
We have enough places where we parse an ifindex, hence introduce a proper parsing function for it, that verifies all parameters.
2015-11-01sd-daemon: verify NOTIFY_SOCKET path lengthLennart Poettering
Better generate a real error then simply connect to the wrong socket.
2015-10-31sd-daemon: increase sd_notify() socket buffer sizeLennart Poettering
Let's make sure we don't start blocking on sd_notify() earlier than necessary, let's bump the socket buffer sizes to 8M. We already do something similar for our logging socket buffers, hence apply a similar bump here.
2015-10-27util-lib: move inotify-related definitions to fs-util.[ch]Lennart Poettering
2015-10-27util-lib: split out allocation calls into alloc-util.[ch]Lennart Poettering
2015-10-27util-lib: split out printf() helpers to stdio-util.hLennart Poettering
2015-10-27io-util.h: move iovec stuff from macro.h to io-util.hLennart Poettering
2015-10-27user-util: move UID/GID related macros from macro.h to user-util.hLennart Poettering
2015-10-27src/basic: rename audit.[ch] → audit-util.[ch] and capability.[ch] → ↵Lennart Poettering
capability-util.[ch] The files are named too generically, so that they might conflict with the upstream project headers. Hence, let's add a "-util" suffix, to clarify that this are just our utility headers and not any official upstream headers.
2015-10-27util-lib: move more locale-related calls to locale-util.[ch]Lennart Poettering
2015-10-27util-lib: move string table stuff into its own string-table.[ch]Lennart Poettering
2015-10-27util-lib: split stat()/statfs()/stavfs() related calls into stat-util.[ch]Lennart Poettering
2015-10-27util-lib: move a number of fs operations into fs-util.[ch]Lennart Poettering
2015-10-27util-lib: introduce dirent-util.[ch] for directory entry callsLennart Poettering
Also, move a couple of more path-related functions to path-util.c.
2015-10-27util: move filename_is_valid() and path_is_safe() to path-util.[ch]Lennart Poettering
2015-10-27util-lib: move more file I/O related calls into fileio.[ch]Lennart Poettering
2015-10-27util-lib: split out hex/dec/oct encoding/decoding into its own fileLennart Poettering
2015-10-27util-lib: split string parsing related calls from util.[ch] into parse-util.[ch]Lennart Poettering
2015-10-26socket-util: move remaining socket-related calls from util.[ch] to ↵Lennart Poettering
socket-util.[ch]
2015-10-26build-sys: add missing makefile symlinkLennart Poettering
2015-10-26util-lib: move ether_addr_to_string() into ether-addr-util.cLennart Poettering
2015-10-26util-lib: split out user/group/uid/gid calls into user-util.[ch]Lennart Poettering
2015-10-26util-lib: split out IO related calls to io-util.[ch]Lennart Poettering
2015-10-25util-lib: split out fd-related operations into fd-util.[ch]Lennart Poettering
There are more than enough to deserve their own .c file, hence move them over.
2015-10-24util-lib: split our string related calls from util.[ch] into its own file ↵Lennart Poettering
string-util.[ch] There are more than enough calls doing string manipulations to deserve its own files, hence do something about it. This patch also sorts the #include blocks of all files that needed to be updated, according to the sorting suggestions from CODING_STYLE. Since pretty much every file needs our string manipulation functions this effectively means that most files have sorted #include blocks now. Also touches a few unrelated include files.
2015-10-24util: split out escaping code into escape.[ch]Lennart Poettering
This really deserves its own file, given how much code this is now.
2015-10-18Merge pull request #1595 from poettering/proxy-fixesDavid Herrmann
bus proxy fixes, and more
2015-10-17sd-bus: fix error handling of pthread API callsLennart Poettering
pthread APIs (unlike the rest of libc) return their errors as positive error codes directly from the functions, rather than using errno. Let's make sure we always handle things that way.
2015-10-15sd-netlink: refcount multicast groupsTom Gundersen
Track the number of matches installed for a given multicast group, and leave the group once no matches depend on it. In order to handle passed-in sockets that are already members of multicast groups we initialize the refcount based on the membership once we take over the socket. This way we will leave the socket in the state we found it once we finish with it. On kernels that do not fully support reading out the multicast group membership we fall back to never leaving any groups (as before).
2015-10-14Merge pull request #1530 from teg/network-fixes-2Lennart Poettering
networkd/libsystemd-network: collection of trivial patches v2
2015-10-12sd-daemon: wipe out memory before using CMSG_NXTHDR()Daniel Mack
CMSG_NXTHDR() checks for cmsg->cmsg_len *after* it increased the pointer. While this makes sense for parsing received messages, that's a pitfall for code crafting messages with this macro. Wipe out the allocated memory to fix this.
2015-10-11sd-netlink: add support for subscribing to ROUTE messagesTom Gundersen
Also, explicitly don't support subscribing to GET or SET messages, as these will never be emitted by the kernel.
2015-10-11sd-netlink: rtnl - add route_get_{scope,tos,table,protocol}()Tom Gundersen
2015-10-09sd-daemon: simply code simplificationLennart Poettering
No change in behaviour, just make the code more obvious.
2015-10-07build-sys: add sd_listen_fds_with_name() to .sym fileLennart Poettering
2015-10-06Merge pull request #1465 from teg/siphash24Lennart Poettering
hashmap/siphash24: refactor hash functions
2015-10-06Merge pull request #1468 from poettering/fdnamesTom Gundersen
Add support for naming fds for socket activation and more
2015-10-06Merge pull request #1466 from kaysievers/wipTom Gundersen
libsystemd: sd-device - translate / vs. ! in sysname
2015-10-06core: add support for naming file descriptors passed using socket activationLennart Poettering
This adds support for naming file descriptors passed using socket activation. The names are passed in a new $LISTEN_FDNAMES= environment variable, that matches the existign $LISTEN_FDS= one and contains a colon-separated list of names. This also adds support for naming fds submitted to the per-service fd store using FDNAME= in the sd_notify() message. This also adds a new FileDescriptorName= setting for socket unit files to set the name for fds created by socket units. This also adds a new call sd_listen_fds_with_names(), that is similar to sd_listen_fds(), but also returns the names of the fds. systemd-activate gained the new --fdname= switch to specify a name for testing socket activation. This is based on #1247 by Maciej Wereski. Fixes #1247.
2015-10-06libsystemd: sd-device - translate / vs. ! in sysnameKay Sievers
The kernel replaces '/' in device names with '!', we translate that back to '/' in sysname, when taking sysname as input, we should translate it back again.
2015-10-05hashmap: hash_funcs - make inputs unambiguousTom Gundersen
Make sure all variable-length inputs are properly terminated or that their length is encoded in some way. This avoids ambiguity of adjacent inputs. E.g., in case of a hash function taking two strings, compressing "ab" followed by "c" is now distinct from "a" followed by "bc".
2015-10-05hashmap: refactor hash_funcTom Gundersen
All our hash functions are based on siphash24(), factor out siphash_init() and siphash24_finalize() and pass the siphash state to the hash functions rather than the hash key. This simplifies the hash functions, and in particular makes composition simpler as calling siphash24_compress() repeatedly on separate chunks of input has the same effect as first concatenating the input and then calling siphash23_compress() on the result.
2015-10-05sd-rtnl: introduce new API to set the NL header flagsSusant Sahani
By default we set as NLM_F_CREATE | NLM_F_EXCL in sd_rtnl_message_new_link But incase of bridge we need to set NLM_F_REQUEST | NLM_F_ACK. If NLM_F_EXCL is set then we are unable to set the parameters. As bridge supports setting properties after creation not during creation.
2015-10-05sd-rtnl: sd-netlink: add support for bridge NL parametrsSusant Sahani
Rename rtnl_link_info_data_bridge_types to rtnl_link_bridge_management_types as they are of nested types of IFLA_AF_SPEC.