From: kostas <> Date: Sat, 18 Oct 1997 03:19:55 +0000 (+0000) Subject: *** empty log message *** X-Git-Tag: SQUID_3_0_PRE1~4777 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=ceab4c00475cd3729050b726b89ff775a1e85e05;p=thirdparty%2Fsquid.git *** empty log message *** --- diff --git a/src/errorpage.cc b/src/errorpage.cc index 7b718e1a81..31488a40f5 100644 --- a/src/errorpage.cc +++ b/src/errorpage.cc @@ -1,6 +1,6 @@ /* - * $Id: errorpage.cc,v 1.76 1997/10/17 04:00:11 wessels Exp $ + * $Id: errorpage.cc,v 1.77 1997/10/17 21:22:46 kostas Exp $ * * DEBUG: section 4 Error Generation * AUTHOR: Duane Wessels @@ -132,12 +132,18 @@ errorConvert(char token, ErrorState * err) break; case 'E': snprintf(buf, CVT_BUF_SZ, "(%d) %s", err->errno, strerror(err->errno)); + p = buf; break; case 'w': - snprintf(buf, CVT_BUF_SZ, "%s", Config.adminEmail); + if (Config.adminEmail) { + snprintf(buf, CVT_BUF_SZ, "%s", Config.adminEmail); + p = buf; + } else + p = "UNKNOWN"; break; case 'h': snprintf(buf, CVT_BUF_SZ, "%s", getMyHostname()); + p = buf; break; /* * e - errno x diff --git a/src/fd.cc b/src/fd.cc index 8c8cfa047b..a98d4794db 100644 --- a/src/fd.cc +++ b/src/fd.cc @@ -36,6 +36,7 @@ void fd_open(int fd, unsigned int type, const char *desc) { fde *F = &fd_table[fd]; + assert(fd >= 0); assert(F->open == 0); F->type = type; fdUpdateBiggest(fd, F->open = FD_OPEN);