The function parse_pid() trivially returns pid, hence it is not
necessary to name the argument for storing result as 'ret_pid'.
return 0;
}
-int parse_pid(const char *s, pid_t* ret_pid) {
+int parse_pid(const char *s, pid_t *ret) {
unsigned long ul = 0;
pid_t pid;
int r;
if (!pid_is_valid(pid))
return -ERANGE;
- if (ret_pid)
- *ret_pid = pid;
+ if (ret)
+ *ret = pid;
return 0;
}
static inline int parse_tristate(const char *v, int *ret) {
return parse_tristate_full(v, NULL, ret);
}
-int parse_pid(const char *s, pid_t* ret_pid);
+int parse_pid(const char *s, pid_t *ret);
int parse_mode(const char *s, mode_t *ret);
int parse_ifindex(const char *s);
int parse_mtu(int family, const char *s, uint32_t *ret);