chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6300b3e
)
core/unit: fix unit_add_target_dependencies() for units with no dependencies
author
Daniel Mack
<zonque@gmail.com>
Thu, 20 Feb 2014 12:29:54 +0000
(13:29 +0100)
committer
Daniel Mack
<zonque@gmail.com>
Thu, 20 Feb 2014 12:29:54 +0000
(13:29 +0100)
For units without any dependencies, r needs to be initialized to 0.
Otherwise, the return value of unit_add_target_dependencies() is
unspecified.
src/core/unit.c
patch
|
blob
|
history
diff --git
a/src/core/unit.c
b/src/core/unit.c
index 21ad434f9d7d88af50bd0a13d58e6693df721f72..016b1e3d869d846b29806e1be9f758c8529f249d 100644
(file)
--- a/
src/core/unit.c
+++ b/
src/core/unit.c
@@
-959,7
+959,7
@@
static int unit_add_target_dependencies(Unit *u) {
Unit *target;
Iterator i;
unsigned k;
- int r;
+ int r
= 0
;
assert(u);