removed an irrelevant cast to off_t in the offset wraparound check.

the expression in question is already of type isc_offset_t, which
is just a typedef for off_t.
This commit is contained in:
David Lawrence
2000-06-06 22:28:21 +00:00
parent 5fda9ca75a
commit 49f64feb02

View File

@@ -1275,8 +1275,8 @@ journal_next(dns_journal_t *j, journal_pos_t *pos) {
* Check for offset wraparound.
*/
if (xhdr.size + sizeof(journal_rawxhdr_t) > ISC_OFFSET_MAXIMUM ||
(off_t)(ISC_OFFSET_MAXIMUM - xhdr.size - sizeof(journal_rawxhdr_t))
< pos->offset) {
ISC_OFFSET_MAXIMUM - xhdr.size - sizeof(journal_rawxhdr_t)
< pos->offset) {
isc_log_write(JOURNAL_COMMON_LOGARGS, ISC_LOG_ERROR,
"%s: offset too large", j->filename);
return (ISC_R_UNEXPECTED);