Implement error messages in the decoder side.

Update issue 7
Status: Started
This commit is contained in:
Petteri Aimonen
2012-08-24 21:22:20 +03:00
parent ea57f74741
commit 0fb5e5e068
12 changed files with 52 additions and 32 deletions

View File

@@ -33,6 +33,10 @@ struct _pb_istream_t
bool (*callback)(pb_istream_t *stream, uint8_t *buf, size_t count);
void *state; /* Free field for use by callback implementation */
size_t bytes_left;
#ifndef PB_NO_ERRMSG
const char *errmsg;
#endif
};
pb_istream_t pb_istream_from_buffer(uint8_t *buf, size_t bufsize);