From c0e17cb315f55009609b1ea979cc9e1845db27bf Mon Sep 17 00:00:00 2001 From: Michiel Broek Date: Wed, 17 Aug 2005 19:33:10 +0000 Subject: [PATCH] NetBSD extra debug --- mbcico/binkp.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/mbcico/binkp.c b/mbcico/binkp.c index 65c4c855..4f0dec31 100644 --- a/mbcico/binkp.c +++ b/mbcico/binkp.c @@ -1036,6 +1036,9 @@ TrType binkp_receiver(void) struct statfs sfs; long written; off_t rxbytes; + int rc1 = 0, nget = bp.blklen, zavail, nput; + char zbuf[ZBLKSIZE]; + char *buf = bp.rxbuf; if (bp.RxState == RxWaitF) { @@ -1264,11 +1267,10 @@ TrType binkp_receiver(void) /* * Receive stream compressed data */ - int rc1 = 0, nget = bp.blklen, zavail, nput; - char zbuf[ZBLKSIZE]; - char *buf = bp.rxbuf; - +Syslog('b', "enter receive stream"); + if (bp.z_idata == NULL) { +Syslog('b', "decompress_init begins"); if (decompress_init(bp.rmode, &bp.z_idata)) { Syslog('+', "Binkp: can't init decompress"); bp.RxState = RxDone; @@ -2860,11 +2862,14 @@ int decompress_init(int type, void **data) #endif #ifdef HAVE_ZLIB_H case CompGZ: { +Syslog('b', "init start %d", sizeof(z_stream)); *data = calloc(1, sizeof(z_stream)); +Syslog('b', "data calloc done"); if (*data == NULL) { Syslog('+', "Binkp: decompress_init: not enough memory (%lu needed)", sizeof(z_stream)); return Z_MEM_ERROR; } +Syslog('b', "begin inflateInit"); return inflateInit((z_stream *)*data); } #endif