X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=src%2Flibudev%2Flibudev-device-private.c;h=fb4c6e2940af511710ba1f023f39ed00047ab39e;hb=9c89c1cabd0357fa4e58a91c4d9233702896b709;hp=aa3b2270e0c9c4c393cb409759005b0260ff6c47;hpb=ff49bc3212cb07d850dcfd59940539773a0be26f;p=elogind.git diff --git a/src/libudev/libudev-device-private.c b/src/libudev/libudev-device-private.c index aa3b2270e..fb4c6e294 100644 --- a/src/libudev/libudev-device-private.c +++ b/src/libudev/libudev-device-private.c @@ -128,10 +128,8 @@ int udev_device_update_db(struct udev_device *udev_device) strscpyl(filename_tmp, sizeof(filename_tmp), filename, ".tmp", NULL); mkdir_parents(filename_tmp, 0755); f = fopen(filename_tmp, "we"); - if (f == NULL) { - log_debug("unable to create temporary db file '%s': %m", filename_tmp); - return -errno; - } + if (f == NULL) + return log_debug_errno(errno, "unable to create temporary db file '%s': %m", filename_tmp); /* * set 'sticky' bit to indicate that we should not clean the