mirror of
https://github.com/morgan9e/systemd
synced 2026-04-14 08:25:20 +09:00
treewide: correct argument comments
This commit is contained in:
@@ -46,7 +46,7 @@ int cg_path_open(const char *controller, const char *path) {
|
||||
_cleanup_free_ char *fs = NULL;
|
||||
int r;
|
||||
|
||||
r = cg_get_path(controller, path, /* item=*/ NULL, &fs);
|
||||
r = cg_get_path(controller, path, /* suffix=*/ NULL, &fs);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
|
||||
@@ -1571,7 +1571,7 @@ static void config_load_type1_entries(
|
||||
/* offset= */ 0,
|
||||
/* size= */ 0,
|
||||
&content,
|
||||
/* ret_size= */ NULL);
|
||||
/* content_size= */ NULL);
|
||||
if (err != EFI_SUCCESS)
|
||||
continue;
|
||||
|
||||
|
||||
@@ -174,7 +174,7 @@ not_found:
|
||||
|
||||
bool smbios_in_hypervisor(void) {
|
||||
/* Look up BIOS Information (Type 0). */
|
||||
const SmbiosTableType0 *type0 = (const SmbiosTableType0 *) get_smbios_table(0, sizeof(SmbiosTableType0), /* left= */ NULL);
|
||||
const SmbiosTableType0 *type0 = (const SmbiosTableType0 *) get_smbios_table(0, sizeof(SmbiosTableType0), /* ret_size_left= */ NULL);
|
||||
if (!type0)
|
||||
return false;
|
||||
|
||||
|
||||
@@ -50,7 +50,7 @@ static int boot_config_load_and_select(
|
||||
else if (r < 0)
|
||||
log_warning_errno(r, "Failed to determine entries reported by boot loader, ignoring: %m");
|
||||
else
|
||||
(void) boot_config_augment_from_loader(config, efi_entries, /* only_auto= */ false);
|
||||
(void) boot_config_augment_from_loader(config, efi_entries, /* auto_only= */ false);
|
||||
}
|
||||
|
||||
return boot_config_select_special_entries(config, /* skip_efivars= */ !!arg_root);
|
||||
|
||||
@@ -25,7 +25,7 @@ int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
|
||||
|
||||
assert_se(str = memdup_suffix0(data, size));
|
||||
|
||||
r = varlink_idl_parse(str, /* line= */ NULL, /* column= */ NULL, &vi);
|
||||
r = varlink_idl_parse(str, /* ret_line= */ NULL, /* column= */ NULL, &vi);
|
||||
if (r < 0) {
|
||||
log_debug_errno(r, "Failed to parse varlink interface definition: %m");
|
||||
return 0;
|
||||
|
||||
@@ -467,7 +467,7 @@ static int load_leases_file(int dir_fd, const char *path, SavedInfo *ret) {
|
||||
path,
|
||||
/* flags = */ 0,
|
||||
&v,
|
||||
/* ret_line = */ NULL,
|
||||
/* reterr_line = */ NULL,
|
||||
/* ret_column = */ NULL);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -1300,7 +1300,7 @@ static int method_create_session(sd_bus_message *message, void *userdata, sd_bus
|
||||
error,
|
||||
uid,
|
||||
leader_pid,
|
||||
/* pidfd = */ -EBADF,
|
||||
/* leader_pidfd = */ -EBADF,
|
||||
service,
|
||||
type,
|
||||
class,
|
||||
@@ -4423,7 +4423,7 @@ int match_job_removed(sd_bus_message *message, void *userdata, sd_bus_error *err
|
||||
|
||||
LIST_FOREACH(sessions_by_user, s, user->sessions)
|
||||
/* Don't propagate user service failures to the client */
|
||||
session_jobs_reply(s, id, unit, /* error = */ NULL);
|
||||
session_jobs_reply(s, id, unit, /* result = */ NULL);
|
||||
|
||||
user_save(user);
|
||||
break;
|
||||
|
||||
@@ -497,7 +497,7 @@ static int netns_child_begin(int netns_fd, int *ret_original_netns_fd) {
|
||||
|
||||
/* Populate new sysfs instance associated with the client netns, to make sd_device usable. */
|
||||
r = mount_nofollow_verbose(LOG_ERR, "sysfs", "/sys/", "sysfs",
|
||||
MS_RDONLY|MS_NOSUID|MS_NOEXEC|MS_NODEV, /* opts = */ NULL);
|
||||
MS_RDONLY|MS_NOSUID|MS_NOEXEC|MS_NODEV, /* options = */ NULL);
|
||||
if (r < 0)
|
||||
return log_error_errno(r, "Failed to mount sysfs on /sys/: %m");
|
||||
|
||||
|
||||
@@ -1671,7 +1671,7 @@ static int event_log_add_component_file(EventLog *el, EventLogComponent *compone
|
||||
path,
|
||||
/* flags= */ 0,
|
||||
&j,
|
||||
/* ret_line= */ NULL,
|
||||
/* reterr_line= */ NULL,
|
||||
/* ret_column= */ NULL);
|
||||
if (r < 0) {
|
||||
log_warning_errno(r, "Failed to parse component file %s, ignoring: %m", path);
|
||||
@@ -5320,7 +5320,7 @@ static int vl_method_make_policy(sd_varlink *link, sd_json_variant *parameters,
|
||||
if (r != 0)
|
||||
return r;
|
||||
|
||||
r = make_policy(p.force, /* recovery_key= */ RECOVERY_PIN_HIDE);
|
||||
r = make_policy(p.force, /* recovery_pin_mode= */ RECOVERY_PIN_HIDE);
|
||||
if (r < 0)
|
||||
return r;
|
||||
if (r == 0)
|
||||
|
||||
@@ -171,7 +171,7 @@ static int run(int argc, char *argv[]) {
|
||||
if (r < 0)
|
||||
return log_error_errno(r, "Failed to get event loop: %m");
|
||||
|
||||
pty_fd = openpt_allocate(O_RDWR|O_NOCTTY|O_NONBLOCK|O_CLOEXEC, /*ret_peer=*/ NULL);
|
||||
pty_fd = openpt_allocate(O_RDWR|O_NOCTTY|O_NONBLOCK|O_CLOEXEC, /*ret_peer_path=*/ NULL);
|
||||
if (pty_fd < 0)
|
||||
return log_error_errno(pty_fd, "Failed to acquire pseudo tty: %m");
|
||||
|
||||
|
||||
@@ -209,7 +209,7 @@ TEST(naptr) {
|
||||
assert(streq(joined, twilio_reply_string));
|
||||
|
||||
_cleanup_(sd_json_variant_unrefp) sd_json_variant *parsed = NULL;
|
||||
assert_se(sd_json_parse(twilio_reply_json, /* flags= */ 0, &parsed, /* ret_line= */ NULL, /* ret_column= */ NULL) >= 0);
|
||||
assert_se(sd_json_parse(twilio_reply_json, /* flags= */ 0, &parsed, /* reterr_line= */ NULL, /* ret_column= */ NULL) >= 0);
|
||||
|
||||
assert_se(sd_json_variant_equal(parsed, a));
|
||||
}
|
||||
|
||||
@@ -1007,7 +1007,7 @@ static int pe_find_uki_sections(
|
||||
if (found->VirtualSize == 0)
|
||||
continue;
|
||||
|
||||
r = pe_read_section_data(fd, found, PE_SECTION_SIZE_MAX, (void**) t->data, /* ret_data= */ NULL);
|
||||
r = pe_read_section_data(fd, found, PE_SECTION_SIZE_MAX, (void**) t->data, /* ret_size= */ NULL);
|
||||
if (r < 0)
|
||||
return log_error_errno(r, "Failed to load contents of section '%s': %m", t->name);
|
||||
}
|
||||
|
||||
@@ -917,7 +917,7 @@ int bus_get_instance_id(sd_bus *bus, sd_id128_t *ret) {
|
||||
|
||||
r = sd_bus_call_method(bus,
|
||||
"org.freedesktop.DBus", "/org/freedesktop/DBus", "org.freedesktop.DBus", "GetId",
|
||||
/* error = */ NULL, &reply,
|
||||
/* ret_error = */ NULL, &reply,
|
||||
NULL);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
@@ -1358,7 +1358,7 @@ int decrypt_credential_and_warn(
|
||||
&IOVEC_MAKE(t->policy_hash_and_blob, le32toh(t->blob_size)),
|
||||
/* n_blobs= */ 1,
|
||||
&IOVEC_MAKE(t->policy_hash_and_blob + le32toh(t->blob_size), le32toh(t->policy_hash_size)),
|
||||
/* n_policy_hash= */ 1,
|
||||
/* n_known_policy_hash= */ 1,
|
||||
/* srk= */ NULL,
|
||||
&tpm2_key);
|
||||
if (r == -EREMOTE)
|
||||
|
||||
@@ -40,7 +40,7 @@ static FactoryResetMode factory_reset_mode_efi_variable(void) {
|
||||
return log_debug_errno(r, "Failed to get EFI variable FactoryResetRequest: %m");
|
||||
|
||||
_cleanup_(sd_json_variant_unrefp) sd_json_variant *v = NULL;
|
||||
r = sd_json_parse(req_str, /* flags= */ 0, &v, /* ret_line= */ NULL, /* ret_column= */ NULL);
|
||||
r = sd_json_parse(req_str, /* flags= */ 0, &v, /* reterr_line= */ NULL, /* ret_column= */ NULL);
|
||||
if (r < 0) {
|
||||
log_debug_errno(r, "EFI variable FactoryResetRequest set to invalid JSON, ignoring: %m");
|
||||
return FACTORY_RESET_UNSPECIFIED;
|
||||
|
||||
@@ -255,7 +255,7 @@ static int load_firmware_data(const char *path, FirmwareData **ret) {
|
||||
path,
|
||||
/* flags= */ 0,
|
||||
&json,
|
||||
/* ret_line= */ NULL,
|
||||
/* reterr_line= */ NULL,
|
||||
/* ret_column= */ NULL);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
Reference in New Issue
Block a user