summaryrefslogtreecommitdiff
path: root/src/libudev/libudev-monitor.c
Commit message (Collapse)AuthorAge
* libudev-monitor: use initializationZbigniew Jędrzejewski-Szmek2015-03-15
|
* libudev: monitor - fix error path in send_deviceTom Gundersen2015-03-12
| | | | Return -errno rather than -1 in case sendmsg() fails.
* remove unused includesThomas Hindoe Paaboel Andersen2015-02-23
| | | | | | This patch removes includes that are not used. The removals were found with include-what-you-use which checks if any of the symbols from a header is in use.
* include <poll.h> instead of <sys/poll.h>Thomas Hindoe Paaboel Andersen2015-02-12
| | | | | | include-what-you-use automatically does this and it makes finding unnecessary harder to spot. The only content of poll.h is a include of sys/poll.h so should be harmless.
* Revert "tree-wide: Always use recvmsg with MSG_CMSG_CLOEXEC"Lennart Poettering2015-02-12
| | | | | | | This reverts commit d6d810fbf8071f8510450dbacd1d083f37603656. It's apparently not OK to pass MSG_CMSG_CLOEXEC to recvmsg() of raw sockets.
* tree-wide: Always use recvmsg with MSG_CMSG_CLOEXECCristian Rodríguez2015-02-10
|
* libudev: monitor - move nulstr parsing to libudev-deviceTom Gundersen2015-01-26
| | | | Hide the details a bit.
* Assorted format fixesZbigniew Jędrzejewski-Szmek2015-01-22
| | | | | Types used for pids and uids in various interfaces are unpredictable. Too bad.
* Add initialization helper for file_handle_unionZbigniew Jędrzejewski-Szmek2015-01-18
|
* libudev: fix check for too long packetTopi Miettinen2015-01-18
| | | | | | | Don't use recvmsg(2) return value to check for too long packets (it doesn't work) but MSG_TRUNC flag. (David: add parantheses around condition)
* libudev: fix strict aliasing violationShawn Paul Landden2014-12-25
|
* treewide: use log_*_errno whenever %m is in the format stringMichal Schmidt2014-11-28
| | | | | | | | | | | If the format string contains %m, clearly errno must have a meaningful value, so we might as well use log_*_errno to have ERRNO= logged. Using: find . -name '*.[ch]' | xargs sed -r -i -e \ 's/log_(debug|info|notice|warning|error|emergency)\((".*%m.*")/log_\1_errno(errno, \2/' Plus some whitespace, linewrap, and indent adjustments.
* treewide: drop unnecessary trailing \n in log_*() callsMichal Schmidt2014-11-28
|
* udev: switch to systemd logging functionsKay Sievers2014-11-13
|
* libudev: we do not log errors from librariesKay Sievers2014-11-13
|
* libudev: monitor - warn if we fail to request SO_PASSCREDTom Gundersen2014-09-18
| | | | The function still succeeds, so there is no functional change. This fixes CID #996288.
* udev: warn when name_to_handle_at is not implementedZbigniew Jędrzejewski-Szmek2014-04-24
| | | | | | | | | We have a bunch of reports from people who have a custom kernel and are confused why udev is not running. Issue a warning on error. Barring an error in the code, the only error that is possible is ENOSYS. https://bugzilla.redhat.com/show_bug.cgi?id=1072966
* util: make sure all our name_to_handle_at() code makes use of file_handle_unionLennart Poettering2014-04-24
|
* implement a union to pad out file_handleDave Reisner2014-04-21
| | | | | | | | | | Cases where name_to_handle_at is used allocated the full struct to be MAX_HANDLE_SZ, and assigned this size to handle_bytes. This is wrong since handle_bytes should describe the length of the flexible array member and not the whole struct. Define a union type which includes sufficient padding to allow assignment of MAX_HANDLE_SZ to be correct.
* udev: remove seqnum API and all assumptions about seqnumsKay Sievers2014-04-13
| | | | | | | | | | | | The way the kernel namespaces have been implemented breaks assumptions udev made regarding uevent sequence numbers. Creating devices in a namespace "steals" uevents and its sequence numbers from the host. It confuses the "udevadmin settle" logic, which might block until util a timeout is reached, even when no uevent is pending. Remove any assumptions about sequence numbers and deprecate libudev's API exposing these numbers; none of that can reliably be used anymore when namespaces are involved.
* everywhere: make use of new0() and macro() macros, and stop using perror()Lennart Poettering2014-02-13
|
* use memzero(foo, length); for all memset(foo, 0, length); callsGreg KH2014-01-31
| | | | | | | | In trying to track down a stupid linker bug, I noticed a bunch of memset() calls that should be using memzero() to make it more "obvious" that the options are correct (i.e. 0 is not the length, but the data to set). So fix up all current calls to memset(foo, 0, length) to memzero(foo, length).
* remove unused variableThomas Hindoe Paaboel Andersen2013-12-19
|
* libudev: monitor - only disallow "udev" type eventsKay Sievers2013-12-18
|
* libudev: disable monitor inside a containerKay Sievers2013-12-18
| | | | | | Uevents are events of the host, which should not leak into a container. Containers do not support hotplug at the moment, and devices and uevents are not namespace aware.
* bus: catch up with kdbus changesKay Sievers2013-12-18
|
* libudev: devices received from udev are always initializedKay Sievers2013-12-18
|
* libudev: always return NULL in _unref() APIsLennart Poettering2013-11-20
| | | | | | | | | | | | | Returning anything else but NULL would suggest the caller's reference might still be valid, but it isn't, because the caller just invoked _unref() after all. This turns the return value into a typesafe shortcut that allows unreffing and resetting a reference in one line. In contrast to solutions for this which take a pointer to a pointer to accomplish the same this solution is just syntactic sugar the developer can make use of but doesn't have to, and this is particularly useful when immediately unreffing objects returned by function calls.
* libudev: always return valid negative error codes on API functionsLennart Poettering2013-11-20
|
* use streq instead of strcmpThomas Hindoe Paaboel Andersen2013-02-13
|
* libudev: update copyright headersKay Sievers2012-11-12
|
* libudev: clarify that udev_monitor_receive_device() is non-blockingKay Sievers2012-06-18
| | | | | Based on a patch from: Sam Thursfield <ssssam@gmail.com> https://bugs.freedesktop.org/show_bug.cgi?id=51202
* udev: silent gcc warningsKay Sievers2012-05-25
|
* udev: update docs, NEWSKay Sievers2012-05-15
|
* udev: libudev - bump soname, remove deprecated functions, introduce symbol ↵Kay Sievers2012-05-15
| | | | versions
* libudev: prefix log macros with 'udev_'Kay Sievers2012-04-26
|
* udev: replace ARRAY_SIZE() with ELEMENTSOF()Kay Sievers2012-04-16
|
* udev: udev_monitor_new_from_socket() - log error and remove from public headerKay Sievers2012-04-15
|
* udev: move libudev, gudev to src/; move gudev/docs/, udev/docs/ to to docs/Kay Sievers2012-04-13