dtlogin: start to resolve static analysis warnings

Also convert some K&R function declarations to ansi
This commit is contained in:
Peter Howkins
2014-12-23 17:49:11 +00:00
parent 29294e0373
commit e54c164fe1
13 changed files with 215 additions and 317 deletions

View File

@@ -49,8 +49,8 @@ char * qualifyWithFirst
char * searchPath
)
{
char * paths = strdup(searchPath);
char * savepaths = paths;
char * paths = NULL;
char * savepaths = NULL;
char * path;
char * chance;
FILE * f;
@@ -60,6 +60,9 @@ FILE * f;
if (filename == NULL || searchPath == NULL)
return NULL;
paths = strdup(searchPath);
savepaths = paths;
while (1) {
/* if there is a :, zero it */