Return 0 length iobuf if wrapping empty iovecs
Summary: Introduction of `folly::IOBuf::wrapIov` and the subsequent change to `WriteChainAsyncTransportWrapper` introduced a subtle change where someone sending a number of 0 length iovs would still get their WriteCallback invoked. This fixes that case and also invokes WriteCallback if no iovs are to be wrapped. Arguably, both of these are invalid uses of the API, but this at least fixes the subtleties. Reviewed By: knekritz Differential Revision: D9379661 fbshipit-source-id: 73d2f7cd1494be4ccccaa9c1fd834ae5410d6421
Showing
Please register or sign in to comment