Commit graph

2 commits

Author SHA1 Message Date
dholland
4a861a6f6b Clean up legacy C.
Now passes gcc -Wall -Wextra -Wmissing-declarations -Wwrite-strings on gcc45.
May build with clang now too.

Changes:
   - use standard headers
   - don't declare own errno, fopen(), getenv(), or malloc()
   - declare own functions
   - declare void functions void
   - avoid implicit int
   - use C89
   - use some const
   - use some static
   - fix signed/unsigned mismatches
   - call execl() properly
   - don't cast return value of malloc
   - initialize struct sigaction correctly
   - use <ctype.h> functions correctly
   - don't index arrays with (signed) char
   - don't put function declarations inside function bodies
   - patch up two uninitialized variables
   - silence some compiler warnings that are not bugs
   - remove some unused objects
and:
   - add patch comments for preexisting patches
   - correct some minor pkglint

As a couple of these things fixed bugs (e.g. the execl calls), bump
PKGREVISION.
2012-12-27 06:13:20 +00:00
is
e45f4a7fbd Mark C. Henderson's port of Matt Fichtenbaums TECO for Ultrix. 2005-12-28 22:29:17 +00:00