From e5f3532cbc4bd2aababe7917cab38294eb64edc8 Mon Sep 17 00:00:00 2001 From: bde Date: Fri, 15 Feb 2002 02:28:50 +0000 Subject: Fixed style bugs in rev.1.5: - missing whitespace - strange version of warn() built out of warnx() + strerror(). Just use warn(). - conversion of just one of the two perror()'s to warn*() Actually use _warn() instead of _warn(), to keep up with namespace- unpollution for warn(). --- lib/libc/gmon/gmon.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'lib/libc/gmon/gmon.c') diff --git a/lib/libc/gmon/gmon.c b/lib/libc/gmon/gmon.c index e825619..f25cbab 100644 --- a/lib/libc/gmon/gmon.c +++ b/lib/libc/gmon/gmon.c @@ -43,8 +43,9 @@ __FBSDID("$FreeBSD$"); #include #include +#include "namespace.h" #include -#include +#include "un-namespace.h" #include #include #include @@ -174,16 +175,16 @@ _mcleanup() } moncontrol(0); - snprintf(outname,sizeof(outname),"%s.gmon",__progname); + snprintf(outname, sizeof(outname), "%s.gmon", __progname); fd = _open(outname, O_CREAT|O_TRUNC|O_WRONLY, 0666); if (fd < 0) { - warnx("_mcleanup: %s - %s",outname,strerror(errno)); + _warn("_mcleanup: %s", outname); return; } #ifdef DEBUG log = _open("gmon.log", O_CREAT|O_TRUNC|O_WRONLY, 0664); if (log < 0) { - perror("_mcleanup: gmon.log"); + _warn("_mcleanup: gmon.log"); return; } len = sprintf(buf, "[mcleanup1] kcount 0x%x ssiz %d\n", -- cgit v1.1