chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
core: fix return value on OOM
[elogind.git]
/
src
/
core
/
busname.c
diff --git
a/src/core/busname.c
b/src/core/busname.c
index 00e56686e5d88dbbe42b9e37c5bac04c4e7fd8b1..1d77292f9b9d98ec40ee36ed353a9e47bc4439c9 100644
(file)
--- a/
src/core/busname.c
+++ b/
src/core/busname.c
@@
-205,7
+205,7
@@
static int busname_verify(BusName *n) {
return -EINVAL;
}
return -EINVAL;
}
- e = str
append
a(n->name, ".busname");
+ e = str
join
a(n->name, ".busname");
if (!unit_has_name(UNIT(n), e)) {
log_unit_error(UNIT(n)->id, "%s's Name= setting doesn't match unit name. Refusing.", UNIT(n)->id);
return -EINVAL;
if (!unit_has_name(UNIT(n), e)) {
log_unit_error(UNIT(n)->id, "%s's Name= setting doesn't match unit name. Refusing.", UNIT(n)->id);
return -EINVAL;
@@
-615,7
+615,7
@@
static int busname_start(Unit *u) {
n->result = BUSNAME_SUCCESS;
busname_enter_making(n);
n->result = BUSNAME_SUCCESS;
busname_enter_making(n);
- return
0
;
+ return
1
;
}
static int busname_stop(Unit *u) {
}
static int busname_stop(Unit *u) {
@@
-638,7
+638,7
@@
static int busname_stop(Unit *u) {
assert(IN_SET(n->state, BUSNAME_REGISTERED, BUSNAME_LISTENING, BUSNAME_RUNNING));
busname_enter_dead(n, BUSNAME_SUCCESS);
assert(IN_SET(n->state, BUSNAME_REGISTERED, BUSNAME_LISTENING, BUSNAME_RUNNING));
busname_enter_dead(n, BUSNAME_SUCCESS);
- return
0
;
+ return
1
;
}
static int busname_serialize(Unit *u, FILE *f, FDSet *fds) {
}
static int busname_serialize(Unit *u, FILE *f, FDSet *fds) {
@@
-975,7
+975,7
@@
static int busname_get_timeout(Unit *u, uint64_t *timeout) {
}
static bool busname_supported(Manager *m) {
}
static bool busname_supported(Manager *m) {
- int supported = -1;
+
static
int supported = -1;
assert(m);
if (supported < 0)
assert(m);
if (supported < 0)