summaryrefslogtreecommitdiffstats
path: root/common
diff options
context:
space:
mode:
Diffstat (limited to 'common')
-rw-r--r--common/resourceaccess.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/common/resourceaccess.cpp b/common/resourceaccess.cpp
index b264619..d2aa969 100644
--- a/common/resourceaccess.cpp
+++ b/common/resourceaccess.cpp
@@ -550,10 +550,12 @@ bool ResourceAccess::processMessageBuffer()
550 Log(d->resourceInstanceIdentifier) << "Received inspection notification."; 550 Log(d->resourceInstanceIdentifier) << "Received inspection notification.";
551 ResourceNotification n; 551 ResourceNotification n;
552 if (buffer->identifier()) { 552 if (buffer->identifier()) {
553 n.id = QByteArray::fromRawData(reinterpret_cast<char const *>(buffer->identifier()->Data()), buffer->identifier()->size()); 553 //Don't use fromRawData, the buffer is gone once we invoke emit notification
554 n.id = QByteArray(reinterpret_cast<char const *>(buffer->identifier()->Data()), buffer->identifier()->size());
554 } 555 }
555 if (buffer->message()) { 556 if (buffer->message()) {
556 n.message = QByteArray::fromRawData(reinterpret_cast<char const *>(buffer->message()->Data()), buffer->message()->size()); 557 //Don't use fromRawData, the buffer is gone once we invoke emit notification
558 n.message = QByteArray(reinterpret_cast<char const *>(buffer->message()->Data()), buffer->message()->size());
557 } 559 }
558 n.type = buffer->type(); 560 n.type = buffer->type();
559 n.code = buffer->code(); 561 n.code = buffer->code();