chiark / gitweb /
use "Out of memory." consistantly (or with "\n")
[elogind.git] / src / fstab-generator / fstab-generator.c
index f832730b4041ee2bb8e2ce29d1a3e7bd6750f88f..89a4d13504fb67d32b66ff497fde58b541a74016 100644 (file)
@@ -98,14 +98,14 @@ static int add_swap(const char *what, struct mntent *me) {
 
         name = unit_name_from_path(what, ".swap");
         if (!name) {
-                log_error("Out of memory");
+                log_error("Out of memory.");
                 r = -ENOMEM;
                 goto finish;
         }
 
-        unit = join(arg_dest, "/", name, NULL);
+        unit = strjoin(arg_dest, "/", name, NULL);
         if (!unit) {
-                log_error("Out of memory");
+                log_error("Out of memory.");
                 r = -ENOMEM;
                 goto finish;
         }
@@ -146,9 +146,9 @@ static int add_swap(const char *what, struct mntent *me) {
         }
 
         if (!noauto) {
-                lnk = join(arg_dest, "/" SPECIAL_SWAP_TARGET ".wants/", name, NULL);
+                lnk = strjoin(arg_dest, "/" SPECIAL_SWAP_TARGET ".wants/", name, NULL);
                 if (!lnk) {
-                        log_error("Out of memory");
+                        log_error("Out of memory.");
                         r = -ENOMEM;
                         goto finish;
                 }
@@ -162,16 +162,16 @@ static int add_swap(const char *what, struct mntent *me) {
 
                 r = device_name(what, &device);
                 if (r < 0) {
-                        log_error("Out of memory");
+                        log_error("Out of memory.");
                         r = -ENOMEM;
                         goto finish;
                 }
 
                 if (r > 0) {
                         free(lnk);
-                        lnk = join(arg_dest, "/", device, ".wants/", name, NULL);
+                        lnk = strjoin(arg_dest, "/", device, ".wants/", name, NULL);
                         if (!lnk) {
-                                log_error("Out of memory");
+                                log_error("Out of memory.");
                                 r = -ENOMEM;
                                 goto finish;
                         }
@@ -256,14 +256,14 @@ static int add_mount(const char *what, const char *where, struct mntent *me) {
 
         name = unit_name_from_path(where, ".mount");
         if (!name)  {
-                log_error("Out of memory");
+                log_error("Out of memory.");
                 r = -ENOMEM;
                 goto finish;
         }
 
-        unit = join(arg_dest, "/", name, NULL);
+        unit = strjoin(arg_dest, "/", name, NULL);
         if (!unit) {
-                log_error("Out of memory");
+                log_error("Out of memory.");
                 r = -ENOMEM;
                 goto finish;
         }
@@ -321,9 +321,9 @@ static int add_mount(const char *what, const char *where, struct mntent *me) {
         }
 
         if (!noauto) {
-                lnk = join(arg_dest, "/", post, nofail || automount ? ".wants/" : ".requires/", name, NULL);
+                lnk = strjoin(arg_dest, "/", post, nofail || automount ? ".wants/" : ".requires/", name, NULL);
                 if (!lnk) {
-                        log_error("Out of memory");
+                        log_error("Out of memory.");
                         r = -ENOMEM;
                         goto finish;
                 }
@@ -340,16 +340,16 @@ static int add_mount(const char *what, const char *where, struct mntent *me) {
 
                         r = device_name(what, &device);
                         if (r < 0) {
-                                log_error("Out of memory");
+                                log_error("Out of memory.");
                                 r = -ENOMEM;
                                 goto finish;
                         }
 
                         if (r > 0) {
                                 free(lnk);
-                                lnk = join(arg_dest, "/", device, ".wants/", name, NULL);
+                                lnk = strjoin(arg_dest, "/", device, ".wants/", name, NULL);
                                 if (!lnk) {
-                                        log_error("Out of memory");
+                                        log_error("Out of memory.");
                                         r = -ENOMEM;
                                         goto finish;
                                 }
@@ -367,14 +367,14 @@ static int add_mount(const char *what, const char *where, struct mntent *me) {
         if (automount && !path_equal(where, "/")) {
                 automount_name = unit_name_from_path(where, ".automount");
                 if (!name) {
-                        log_error("Out of memory");
+                        log_error("Out of memory.");
                         r = -ENOMEM;
                         goto finish;
                 }
 
-                automount_unit = join(arg_dest, "/", automount_name, NULL);
+                automount_unit = strjoin(arg_dest, "/", automount_name, NULL);
                 if (!automount_unit) {
-                        log_error("Out of memory");
+                        log_error("Out of memory.");
                         r = -ENOMEM;
                         goto finish;
                 }
@@ -408,9 +408,9 @@ static int add_mount(const char *what, const char *where, struct mntent *me) {
                 }
 
                 free(lnk);
-                lnk = join(arg_dest, "/", post, nofail ? ".wants/" : ".requires/", automount_name, NULL);
+                lnk = strjoin(arg_dest, "/", post, nofail ? ".wants/" : ".requires/", automount_name, NULL);
                 if (!lnk) {
-                        log_error("Out of memory");
+                        log_error("Out of memory.");
                         r = -ENOMEM;
                         goto finish;
                 }
@@ -459,14 +459,14 @@ static int parse_fstab(void) {
 
                 what = fstab_node_to_udev_node(me->mnt_fsname);
                 if (!what) {
-                        log_error("Out of memory");
+                        log_error("Out of memory.");
                         r = -ENOMEM;
                         goto finish;
                 }
 
                 where = strdup(me->mnt_dir);
                 if (!where) {
-                        log_error("Out of memory");
+                        log_error("Out of memory.");
                         free(what);
                         r = -ENOMEM;
                         goto finish;