digideskio / protobuf-c

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

Support syslog or other non-stdout-based way to see what errors occur on unpack #26

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
Currently the only output we can see if unpack fails goes to stdout. Since
our program runs as a daemon, this is lost to us. How about a configurable
log handler (like the allocators) that this will call?

Original issue reported on code.google.com by appnexus...@gmail.com on 16 Oct 2009 at 2:11

GoogleCodeExporter commented 8 years ago
The best way (in order to maintain compatibility) is probably to shove a 
function 
pointer into the allocator.  Otherwise it'll be a compatibility headache.

Original comment by lahike...@gmail.com on 5 Feb 2010 at 12:10

GoogleCodeExporter commented 8 years ago

Original comment by lahike...@gmail.com on 15 Sep 2010 at 2:43

GoogleCodeExporter commented 8 years ago
We should define a ProtobufCErrorInfo structure so that we can extend our error 
handling w/o changing the API.  Minimal members:
    const char *message;
    ProtobufCErrorCode code;

Perhaps:
    unsigned stack_depth;
    const ProtobufCMessageDescriptor *stack[16];
    const ProtobufCFieldDescriptor *stack_field[16];
    protobuf_c_boolean stack_truncated;

Original comment by lahike...@gmail.com on 16 Sep 2010 at 3:02