commit
429b2fa87e
|
@ -272,31 +272,19 @@ bool transAsyncPoolIsEmpty(SAsyncPool* pool);
|
||||||
} \
|
} \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
#define ASYNC_CHECK_HANDLE(exh1, id) \
|
#define ASYNC_CHECK_HANDLE(exh1, id) \
|
||||||
do { \
|
do { \
|
||||||
if (id > 0) { \
|
if (id > 0) { \
|
||||||
SExHandle* exh2 = transAcquireExHandle(transGetRefMgt(), id); \
|
SExHandle* exh2 = transAcquireExHandle(transGetRefMgt(), id); \
|
||||||
if (exh2 == NULL || id != exh2->refId) { \
|
if (exh2 == NULL || id != exh2->refId) { \
|
||||||
tTrace("handle %p except, may already freed, ignore msg, ref1:%" PRIu64 ", ref2:%" PRIu64, exh1, \
|
tDebug("ref:%" PRId64 " already released" PRIu64, id); \
|
||||||
exh2 ? exh2->refId : 0, id); \
|
code = terrno; \
|
||||||
code = terrno; \
|
goto _return1; \
|
||||||
goto _return1; \
|
} \
|
||||||
} \
|
} else { \
|
||||||
} else if (id == 0) { \
|
tWarn("invalid handle to release"); \
|
||||||
tTrace("handle step2"); \
|
goto _return2; \
|
||||||
SExHandle* exh2 = transAcquireExHandle(transGetRefMgt(), id); \
|
} \
|
||||||
if (exh2 == NULL || id == exh2->refId) { \
|
|
||||||
tTrace("handle %p except, may already freed, ignore msg, ref1:%" PRIu64 ", ref2:%" PRIu64, exh1, id, \
|
|
||||||
exh2 ? exh2->refId : 0); \
|
|
||||||
code = terrno; \
|
|
||||||
goto _return1; \
|
|
||||||
} else { \
|
|
||||||
id = exh1->refId; \
|
|
||||||
} \
|
|
||||||
} else if (id < 0) { \
|
|
||||||
tTrace("handle step3"); \
|
|
||||||
goto _return2; \
|
|
||||||
} \
|
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
int32_t transInitBuffer(SConnBuffer* buf);
|
int32_t transInitBuffer(SConnBuffer* buf);
|
||||||
|
|
Loading…
Reference in New Issue