372046933 commented on code in PR #2009:
URL: https://github.com/apache/incubator-brpc/pull/2009#discussion_r1030998420


##########
src/butil/iobuf.cpp:
##########
@@ -1211,6 +1211,9 @@ int IOBuf::append_user_data(void* data, size_t size, void 
(*deleter)(void*)) {
         LOG(FATAL) << "data_size=" << size << " is too large";
         return -1;
     }
+    if (!size) {
+        return 0;

Review Comment:
   @wwbmmm Could you have a look and decide which is better?



-- 
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: dev-unsubscr...@brpc.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@brpc.apache.org
For additional commands, e-mail: dev-h...@brpc.apache.org

Reply via email to