From b1c4f94606b6a1b9223acb2c1722bfe3bce26933 Mon Sep 17 00:00:00 2001 From: Aaron Seigo Date: Tue, 16 Dec 2014 17:00:45 +0100 Subject: --potentialMemoryLeak; --- common/clientapi.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'common') diff --git a/common/clientapi.h b/common/clientapi.h index fe60d9c..6054130 100644 --- a/common/clientapi.h +++ b/common/clientapi.h @@ -76,7 +76,10 @@ namespace async { QSharedPointer > emitter() { - mResultEmitter = QSharedPointer >(new ResultEmitter()); + if (!mResultEmitter) { + mResultEmitter = QSharedPointer >(new ResultEmitter()); + } + return mResultEmitter; } -- cgit v1.2.3