← Commit list

d6e8f9450

Denis Vlasenko
Denis Vlasenko
2008-12-29
FAILED Duration: 37s

Subject

sysctl: fix gcc warning (false positive)

Binary

No binary (build failed)

Architecture & Compiler Flags

Architecture: x86_64-linux-gnu Compiler: gcc (Ubuntu 11.4.0-1ubuntu1~22.04.3) 11.4.0

—

Build Log

(log yok)

Commit Diff GitHub →

procps/sysctl.c+3 -2
@@ -97,7 +97,8 @@ static int sysctl_handle_preload_file(const char *filename)
static int sysctl_act_on_setting(char *setting)
{
int fd, retval = EXIT_SUCCESS;
- char *cptr, *outname, *value;
+ char *cptr, *outname;
+ char *value = value; /* for compiler */
outname = xstrdup(setting);
@@ -235,7 +236,7 @@ static void sysctl_dots_to_slashes(char *name)
*/
end = name + strlen(name);
last_good = name - 1;
- *end = '.'; /* trick the loop in trying full name too */
+ *end = '.'; /* trick the loop into trying full name too */
again:
cptr = end;