From: wessels <> Date: Fri, 20 Jun 1997 11:26:08 +0000 (+0000) Subject: fix assertions X-Git-Tag: SQUID_3_0_PRE1~4920 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=f52826a1f292ab51fc849b84b94d1cbdfe3ff9ab;p=thirdparty%2Fsquid.git fix assertions --- diff --git a/src/comm.cc b/src/comm.cc index 61b3355038..ed5f9c97bd 100644 --- a/src/comm.cc +++ b/src/comm.cc @@ -1,6 +1,6 @@ /* - * $Id: comm.cc,v 1.169 1997/06/20 05:08:30 wessels Exp $ + * $Id: comm.cc,v 1.170 1997/06/20 05:26:08 wessels Exp $ * * DEBUG: section 5 Socket Functions * AUTHOR: Harvest Derived @@ -584,7 +584,7 @@ comm_close(int fd) fde = &fd_table[fd]; if (!fde->open) return; - assert(fd_table[fd].type =! FD_FILE); + assert(fde->type != FD_FILE); fde->open = 0; CommWriteStateCallbackAndFree(fd, COMM_ERROR); commCallCloseHandlers(fd); diff --git a/src/ftp.cc b/src/ftp.cc index 329791b09c..85e2dc3a7b 100644 --- a/src/ftp.cc +++ b/src/ftp.cc @@ -1,6 +1,6 @@ /* - * $Id: ftp.cc,v 1.127 1997/06/20 02:22:11 wessels Exp $ + * $Id: ftp.cc,v 1.128 1997/06/20 05:26:09 wessels Exp $ * * DEBUG: section 9 File Transfer Protocol (FTP) * AUTHOR: Harvest Derived @@ -225,7 +225,8 @@ ftpTimeout(int fd, void *data) { FtpStateData *ftpState = data; StoreEntry *entry = ftpState->entry; - debug(9, 4) ("ftpLifeTimeExpire: FD %d: '%s'\n", fd, entry->url); + assert(cbdataValid(ftpState)); + debug(9, 4) ("ftpTimeout: FD %d: '%s'\n", fd, entry->url); storeAbort(entry, ERR_READ_TIMEOUT, NULL, 0); if (ftpState->data.fd >= 0) comm_close(ftpState->data.fd);