formatting cleanup src/*.c

Remove trailing spaces, and remove tabs from the files that had
trailing spaces.

Also, rndorcname() was using a random value to terminate a loop
and was recalculating a new one each iteration.
This commit is contained in:
PatR
2018-10-02 16:53:22 -07:00
parent 1110786ec2
commit 14bef9a02d
16 changed files with 75 additions and 80 deletions
+17 -14
View File
@@ -666,7 +666,7 @@ void
really_close()
{
int fd;
if (lftrack.init) {
fd = lftrack.fd;
@@ -2156,24 +2156,27 @@ char sep;
return (char *) 0;
while (*str) {
if (*str == sep) nsep++;
str++;
if (*str == sep)
nsep++;
str++;
}
csep = rn2(nsep);
str = begin;
while ((csep > 0) && *str) {
str++;
if (*str == sep) csep--;
str++;
if (*str == sep)
csep--;
}
if (*str) {
if (*str == sep) str++;
begin = str;
while (*str && *str != sep) {
str++;
len++;
}
*str = '\0';
if (len)
if (*str == sep)
str++;
begin = str;
while (*str && *str != sep) {
str++;
len++;
}
*str = '\0';
if (len)
return begin;
}
return (char *) 0;
@@ -3582,7 +3585,7 @@ const char *reason; /* explanation */
void
testinglog(filenm, type, reason)
const char *filenm; /* ad hoc file name */
const char *type;
const char *type;
const char *reason; /* explanation */
{
FILE *lfile;