]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
treewide: correct argument comment to 'ret' where applicable
authorJelle van der Waa <jvanderwaa@redhat.com>
Tue, 3 Jun 2025 13:58:24 +0000 (15:58 +0200)
committerJelle van der Waa <jvanderwaa@redhat.com>
Wed, 4 Jun 2025 11:32:24 +0000 (13:32 +0200)
For functions with one return argument prefer 'ret' as argument comment.

src/core/main.c
src/gpt-auto-generator/gpt-auto-generator.c
src/import/curl-util.c
src/login/logind-dbus.c
src/nsresourced/nsresourcework.c
src/nsresourced/userns-registry.c

index caff74cb34ec01428ab2a6fdbde28546c5ff9c7d..d63814db1a70354185b4f0a59ea809111ebb830f 100644 (file)
@@ -2461,7 +2461,7 @@ static int initialize_runtime(
                         (void) machine_id_setup(/* root = */ NULL, arg_machine_id,
                                                 (first_boot ? MACHINE_ID_SETUP_FORCE_TRANSIENT : 0) |
                                                 (arg_machine_id_from_firmware ? MACHINE_ID_SETUP_FORCE_FIRMWARE : 0),
-                                                /* ret_machine_id = */ NULL);
+                                                /* ret = */ NULL);
                         (void) hostname_setup(/* really = */ true);
                         (void) loopback_setup();
 
index 1f8d845c6f5fa5af313b912d25904b144f66f968..029e99a30387e75c3ad7e58f43debb350c65828a 100644 (file)
@@ -816,7 +816,7 @@ static int add_root_mount(void) {
                         return 0;
                 }
 
-                r = efi_loader_get_device_part_uuid(/* ret_uuid= */ NULL);
+                r = efi_loader_get_device_part_uuid(/* ret= */ NULL);
                 if (r == -ENOENT) {
                         log_notice("EFI loader partition unknown, not processing %s.\n"
                                    "(The boot loader did not set EFI variable LoaderDevicePartUUID.)",
index 82a1fc132ac303d9ba524fbacb1889d8497172f2..4747d0993a8c38c72996ee43eb2148850aaf0f7d 100644 (file)
@@ -17,7 +17,7 @@ static void curl_glue_check_finished(CurlGlue *g) {
         assert(g);
 
         /* sd_event_get_exit_code() returns -ENODATA if no exit was scheduled yet */
-        r = sd_event_get_exit_code(g->event, /* ret_code= */ NULL);
+        r = sd_event_get_exit_code(g->event, /* ret= */ NULL);
         if (r >= 0)
                 return; /* exit scheduled? Then don't process this anymore */
         if (r != -ENODATA)
index a6d0bb189be9330062c9c7f75d3c8a1fd0bd5305..e13b09112824537002dc755807967f6f96855180 100644 (file)
@@ -935,7 +935,7 @@ int manager_create_session(
         }
 
         /* Check if we are already in a logind session, and if so refuse. */
-        r = manager_get_session_by_pidref(m, leader, /* ret_session= */ NULL);
+        r = manager_get_session_by_pidref(m, leader, /* ret= */ NULL);
         if (r < 0)
                 return log_debug_errno(
                                 r,
index f1c48a1e810d6f96b1625b4267691e4c144157cf..11a6df41168adca9615916aa91392f065c205d74 100644 (file)
@@ -379,13 +379,13 @@ static int uid_is_available(
         if (r > 0)
                 return false;
 
-        r = userdb_by_uid(candidate, /* match= */ NULL, USERDB_AVOID_MULTIPLEXER, /* ret_record= */ NULL);
+        r = userdb_by_uid(candidate, /* match= */ NULL, USERDB_AVOID_MULTIPLEXER, /* ret= */ NULL);
         if (r >= 0)
                 return false;
         if (r != -ESRCH)
                 return r;
 
-        r = groupdb_by_gid(candidate, /* match= */ NULL, USERDB_AVOID_MULTIPLEXER, /* ret_record= */ NULL);
+        r = groupdb_by_gid(candidate, /* match= */ NULL, USERDB_AVOID_MULTIPLEXER, /* ret= */ NULL);
         if (r >= 0)
                 return false;
         if (r != -ESRCH)
@@ -416,13 +416,13 @@ static int name_is_available(
         if (!user_name)
                 return -ENOMEM;
 
-        r = userdb_by_name(user_name, /* match= */ NULL, USERDB_AVOID_MULTIPLEXER, /* ret_record= */ NULL);
+        r = userdb_by_name(user_name, /* match= */ NULL, USERDB_AVOID_MULTIPLEXER, /* ret= */ NULL);
         if (r >= 0)
                 return false;
         if (r != -ESRCH)
                 return r;
 
-        r = groupdb_by_name(user_name, /* match= */ NULL, USERDB_AVOID_MULTIPLEXER, /* ret_record= */ NULL);
+        r = groupdb_by_name(user_name, /* match= */ NULL, USERDB_AVOID_MULTIPLEXER, /* ret= */ NULL);
         if (r >= 0)
                 return false;
         if (r != -ESRCH)
index 8d31d16359172bcc9dbe6d06b13abe8f9d0d116c..155b3c3f20a69c59efa327c3f00e991ad78e0c3d 100644 (file)
@@ -738,7 +738,7 @@ static int userns_destroy_netif(sd_netlink **rtnl, const char *name) {
         if (r < 0)
                 return r;
 
-        r = sd_netlink_call(*rtnl, m, /* timeout_usec= */ 0, /* ret_reply= */ NULL);
+        r = sd_netlink_call(*rtnl, m, /* timeout_usec= */ 0, /* ret= */ NULL);
         if (ERRNO_IS_NEG_DEVICE_ABSENT(r)) /* Already gone? */
                 return 0;
         if (r < 0)