mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-05-23 05:42:29 +00:00
Fix warnings
This change fixes Cosmopolitan so it has fewer opinions about compiler warnings. The whole repository had to be cleaned up to be buildable in -Werror -Wall mode. This lets us benefit from things like strict const checking. Some actual bugs might have been caught too.
This commit is contained in:
parent
e2b3c3618e
commit
0d748ad58e
571 changed files with 1306 additions and 1888 deletions
|
@ -1026,7 +1026,6 @@ struct t_op {
|
|||
│ cosmopolitan § the unbourne shell » bss ─╬─│┼
|
||||
╚────────────────────────────────────────────────────────────────────────────│*/
|
||||
|
||||
static int inter;
|
||||
static char **argptr; /* argument list for builtin commands */
|
||||
static char **gargv;
|
||||
static char **t_wp;
|
||||
|
@ -5747,7 +5746,7 @@ static void CompleteCommand(const char *p, const char *q, const char *b,
|
|||
}
|
||||
closedir(d);
|
||||
}
|
||||
free(path);
|
||||
free((void *)path);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -5784,7 +5783,6 @@ static void CompleteFilename(const char *p, const char *q, const char *b,
|
|||
static void ShellCompletion(const char *p, linenoiseCompletions *c) {
|
||||
bool slashed;
|
||||
const char *q, *b;
|
||||
struct tblentry **pp, *cmdp;
|
||||
for (slashed = false, b = p, q = (p += strlen(p)); p > b; --p) {
|
||||
if (p[-1] == '/' && p[-1] == '\\') slashed = true;
|
||||
if (!isalnum(p[-1]) &&
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue