fix invalid read
This commit is contained in:
parent
959389badf
commit
3afe4cc458
|
@ -6032,12 +6032,15 @@ void qDestroyQueryInfo(qinfo_t qHandle) {
|
||||||
qDebug("QInfo:%p dec refCount, value:%d", pQInfo, ref);
|
qDebug("QInfo:%p dec refCount, value:%d", pQInfo, ref);
|
||||||
|
|
||||||
if (ref == 0) {
|
if (ref == 0) {
|
||||||
if (pQInfo->fn != NULL) {
|
_qinfo_free_fn_t fn = pQInfo->fn;
|
||||||
assert(pQInfo->param != NULL);
|
void* param = pQInfo->param;
|
||||||
pQInfo->fn(pQInfo->param);
|
|
||||||
}
|
|
||||||
|
|
||||||
doDestoryQueryInfo(pQInfo);
|
doDestoryQueryInfo(pQInfo);
|
||||||
|
if (fn != NULL) {
|
||||||
|
assert(param != NULL);
|
||||||
|
fn(param);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue