From ed564186e14c79c767096f4b306dc3c6c5bd2e7d Mon Sep 17 00:00:00 2001 From: Petteri Aimonen Date: Thu, 24 Oct 2013 21:45:39 +0300 Subject: Detect invalid sizes when encoding bytes fields. --- tests/common/unittestproto.proto | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'tests/common/unittestproto.proto') diff --git a/tests/common/unittestproto.proto b/tests/common/unittestproto.proto index 7024942e..eb3e7dec 100644 --- a/tests/common/unittestproto.proto +++ b/tests/common/unittestproto.proto @@ -12,6 +12,10 @@ message StringMessage { required string data = 1 [(nanopb).max_size = 10]; } +message BytesMessage { + required bytes data = 1 [(nanopb).max_size = 16]; +} + message CallbackArray { // We cheat a bit and use this message for testing other types, too. // Nanopb does not care about the actual defined data type for callback -- cgit