From: Thomas Hindoe Paaboel Andersen Date: Sat, 28 Feb 2015 22:39:55 +0000 (+0100) Subject: core: fix return value on OOM X-Git-Tag: v219.0~540 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=commitdiff_plain;h=c43b2132f37264600cc26e07c8d85dfdd6c969f0;ds=sidebyside core: fix return value on OOM --- diff --git a/src/core/device.c b/src/core/device.c index e41ed4149..eb976b860 100644 --- a/src/core/device.c +++ b/src/core/device.c @@ -209,6 +209,8 @@ static int device_update_description(Unit *u, struct udev_device *dev, const cha j = strjoin(model, " ", label, NULL); if (j) r = unit_set_description(u, j); + else + r = -ENOMEM; } else r = unit_set_description(u, model); } else