Fix bug in backwards_compatibility test case.
The memset() filled also the extensions field, which was just waiting for a crash to happen.
This commit is contained in:
@@ -22,10 +22,7 @@
|
||||
the decoding and checks the fields. */
|
||||
bool check_alltypes(pb_istream_t *stream, int mode)
|
||||
{
|
||||
AllTypes alltypes;
|
||||
|
||||
/* Fill with garbage to better detect initialization errors */
|
||||
memset(&alltypes, 0xAA, sizeof(alltypes));
|
||||
AllTypes alltypes = {0};
|
||||
|
||||
if (!pb_decode(stream, AllTypes_fields, &alltypes))
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user