shiyilei / protobuf-c

Automatically exported from code.google.com/p/protobuf-c
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

RPC server closures with output==NULL are not parsed properly on the client side #78

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Server function calls closure(NULL, closure_data);
2. server_connection_response_closure() sets in the header status 
PROTOBUF_C_STATUS_CODE_SERVICE_FAILED and message length 0.
3. handle_client_fd_events() ignores the status field and tries to unpack 
message. If output message has required fields, protobuf_c_message_unpack() 
fails with message "unable to unpack msg of length 0", otherwise it returns 
empty message.

What is the expected output? What do you see instead?
Client closure should always receive output==NULL with no error message on 
stderr.

What version of the product are you using? On what operating system?
protobuf-c 0.15, Ubuntu.

Please provide any additional information below.

Original issue reported on code.google.com by l...@zadarastorage.com on 31 Jan 2012 at 12:31