summaryrefslogtreecommitdiffstats
path: root/src/hostname
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2013-11-11 19:34:13 +0100
committerLennart Poettering <lennart@poettering.net>2013-11-12 00:12:43 +0100
commitafc6adb5ec7e73bc13156c43f52fb015cd80cc68 (patch)
tree999c8810a856d98826900c81c6bfb42fe4dc0ee7 /src/hostname
parenttest: fix minor memory leak in test-event (diff)
downloadsystemd-afc6adb5ec7e73bc13156c43f52fb015cd80cc68.tar.xz
systemd-afc6adb5ec7e73bc13156c43f52fb015cd80cc68.zip
bus: introduce concept of a "default" event loop per-thread and make use of it everywhere
Try to emphasize a bit that there should be a mapping between event loops and threads, hence introduce a logic that there's one "default" event loop for each thread, that can be queried via "sd_event_default()".
Diffstat (limited to 'src/hostname')
-rw-r--r--src/hostname/hostnamed.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/hostname/hostnamed.c b/src/hostname/hostnamed.c
index 35dccf8cb6..d2f0b022e5 100644
--- a/src/hostname/hostnamed.c
+++ b/src/hostname/hostnamed.c
@@ -643,7 +643,7 @@ int main(int argc, char *argv[]) {
goto finish;
}
- r = sd_event_new(&event);
+ r = sd_event_default(&event);
if (r < 0) {
log_error("Failed to allocate event loop: %s", strerror(-r));
goto finish;