summaryrefslogtreecommitdiff
path: root/src/udev/udevd.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2014-02-17 08:39:47 -0500
committerAnthony G. Basile <blueness@gentoo.org>2014-02-21 10:05:22 -0500
commit9fa108ac48c9b76111589967184436bf63109731 (patch)
treea17d913ab78fdb340c1b7ce13c83563937cc316c /src/udev/udevd.c
parentc1db5c60e38fa4b1cd2c590dbc8ce95c4fc3844b (diff)
everywhere: make use of new0() and macro() macros, and stop using perror()
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
Diffstat (limited to 'src/udev/udevd.c')
-rw-r--r--src/udev/udevd.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/udev/udevd.c b/src/udev/udevd.c
index ae2067cddf..d9d3d85f8b 100644
--- a/src/udev/udevd.c
+++ b/src/udev/udevd.c
@@ -200,7 +200,7 @@ static void worker_new(struct event *event)
udev_monitor_allow_unicast_sender(worker_monitor, monitor);
udev_monitor_enable_receiving(worker_monitor);
- worker = calloc(1, sizeof(struct worker));
+ worker = new0(struct worker, 1);
if (worker == NULL) {
udev_monitor_unref(worker_monitor);
return;
@@ -431,7 +431,7 @@ static int event_queue_insert(struct udev_device *dev)
{
struct event *event;
- event = calloc(1, sizeof(struct event));
+ event = new0(struct event, 1);
if (event == NULL)
return -1;