BewareMyPower commented on code in PR #66:
URL: https://github.com/apache/pulsar-client-cpp/pull/66#discussion_r1004321666


##########
lib/SharedBuffer.h:
##########
@@ -203,6 +203,13 @@ class SharedBuffer {
         writeIdx_ = 0;
     }
 
+    bool pop(std::string& target) {
+        if (data_ == nullptr) return false;

Review Comment:
   The returned value is always ignored. I think we should throw an exception 
to disable `moveDataIntoString` on an invalid `Message` object, i.e. built from 
a `MessageBuilder` whose content was set by `setAllocatedContent` .



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to