Date: Tue, 1 Apr 1997 19:38:31 -0800 (PST) From: "Andrey A. Chernov" <ache> To: CVS-committers, cvs-all, cvs-lib Subject: cvs commit: src/lib/libutil uucplock.3 uucplock.c Message-ID: <199704020338.TAA02019@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
ache 97/04/01 19:38:30
Modified: lib/libutil uucplock.3 uucplock.c
Log:
Remove unused USE_PERROR define and syslog.h include
Use snprintf instead of sprintf to avoid buffer overflows
Use snprintf in uu_lockerr instead of lots of hardcoded constants
and not null-terminated strncpy
Return "" for OK and "device in use" for INUSE, it allows simple
strcpy(buf, uu_lockerr(retcode)) without testing for special OK
case (NULL was there) and obtaining meaningful result for INUSE
("" was there) without special testing for it too.
Revision Changes Path
1.4 +3 -6 src/lib/libutil/uucplock.3
1.3 +14 -19 src/lib/libutil/uucplock.c
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199704020338.TAA02019>
