mirror of
https://github.com/edeproject/ede.git
synced 2023-08-10 21:13:03 +03:00
Fixed some warnings
This commit is contained in:
parent
70964d806c
commit
427602bed6
@ -463,11 +463,11 @@ int main(int ac, char **av)
|
|||||||
last_off = 0;
|
last_off = 0;
|
||||||
do
|
do
|
||||||
{
|
{
|
||||||
sp = fgets(string, 256, inf);
|
sp = (unsigned char*)fgets(string, 256, inf);
|
||||||
if (sp == NULL || STR_ENDSTRING(sp, Tbl))
|
if (sp == NULL || STR_ENDSTRING(sp, Tbl))
|
||||||
{
|
{
|
||||||
pos = ftell(inf);
|
pos = ftell(inf);
|
||||||
length = pos - last_off - (sp ? strlen(sp) : 0);
|
length = pos - last_off - (sp ? strlen((const char*)sp) : 0);
|
||||||
if (!length)
|
if (!length)
|
||||||
/* Here's where we go back and fix things, if the
|
/* Here's where we go back and fix things, if the
|
||||||
* 'fortune' just read was the null string.
|
* 'fortune' just read was the null string.
|
||||||
@ -490,7 +490,7 @@ int main(int ac, char **av)
|
|||||||
}
|
}
|
||||||
else if (first)
|
else if (first)
|
||||||
{
|
{
|
||||||
for (nsp = sp; !isalnum(*nsp); nsp++)
|
for (nsp = (char*)sp; !isalnum(*nsp); nsp++)
|
||||||
continue;
|
continue;
|
||||||
ALLOC(Firstch, Num_pts);
|
ALLOC(Firstch, Num_pts);
|
||||||
fp = &Firstch[Num_pts - 1];
|
fp = &Firstch[Num_pts - 1];
|
||||||
@ -529,9 +529,9 @@ int main(int ac, char **av)
|
|||||||
puts("There was 1 string");
|
puts("There was 1 string");
|
||||||
else
|
else
|
||||||
printf("There were %ld strings\n", Num_pts - 1);
|
printf("There were %ld strings\n", Num_pts - 1);
|
||||||
printf("Longest string: %lu byte%s\n", Tbl.str_longlen,
|
printf("Longest string: %u byte%s\n", Tbl.str_longlen,
|
||||||
Tbl.str_longlen == 1 ? "" : "s");
|
Tbl.str_longlen == 1 ? "" : "s");
|
||||||
printf("Shortest string: %lu byte%s\n", Tbl.str_shortlen,
|
printf("Shortest string: %u byte%s\n", Tbl.str_shortlen,
|
||||||
Tbl.str_shortlen == 1 ? "" : "s");
|
Tbl.str_shortlen == 1 ? "" : "s");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user