From 08f29ef2554bc1310c1ff54996bbc9c753933f46 Mon Sep 17 00:00:00 2001 From: Douglas Clowes Date: Wed, 6 Aug 2014 10:32:27 +1000 Subject: [PATCH] Move "Timeout trace" in asyncqueue trace logging --- asyncqueue.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/asyncqueue.c b/asyncqueue.c index d894e2b3..d551912c 100644 --- a/asyncqueue.c +++ b/asyncqueue.c @@ -465,18 +465,18 @@ static int CommandTimeout(void *cntx, int mode) pAsyncQueue self = (pAsyncQueue) cntx; pAQ_Cmd myCmd = self->command_head; self->nw_tmr = 0; + if (self->trace) { + struct timeval tv; + gettimeofday(&tv, NULL); + SICSLogTimePrintf(eLog, &tv, + "Timeout Trace on AsyncQueue %s", self->queue_name); + SICSLogWriteHexTime(myCmd->tran->inp_buf, myCmd->tran->inp_idx, eLog, &tv); + } if (myCmd->retries > 0) { --myCmd->retries; StartCommand(self); } else { int iRet; - if (self->trace) { - struct timeval tv; - gettimeofday(&tv, NULL); - SICSLogTimePrintf(eLog, &tv, - "Timeout Trace on AsyncQueue %s", self->queue_name); - SICSLogWriteHexTime(myCmd->tran->inp_buf, myCmd->tran->inp_idx, eLog, &tv); - } iRet = self->protocol->handleEvent(self->protocol, myCmd->tran, AQU_TIMEOUT);