Expanding the tests to better cover decoding from memory buffer.

git-svn-id: https://svn.kapsi.fi/jpa/nanopb@1090 e3a754e5-d11d-0410-8d38-ebb782a927b9
This commit is contained in:
Petteri Aimonen
2011-12-30 08:57:27 +00:00
parent 1506450b11
commit a3f5e4d81f
4 changed files with 104 additions and 27 deletions

View File

@@ -22,7 +22,7 @@ int main()
/* Now encode it and check if we succeeded. */
if (pb_encode(&stream, Person_fields, &person))
{
fwrite(buffer, stream.bytes_written, 1, stdout);
fwrite(buffer, 1, stream.bytes_written, stdout);
return 0; /* Success */
}
else