[Spice-commits] Branch 'wip2' - spice.proto
Marc-André Lureau
elmarco at kemper.freedesktop.org
Wed Mar 21 05:08:50 PDT 2012
spice.proto | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit e7fa8460642c2185e6145e5200062ece49c4f75b
Author: Marc-André Lureau <marcandre.lureau at gmail.com>
Date: Tue Mar 20 21:38:33 2012 +0100
spice.proto: fix demarshaller crash with name message
It turned out the demarshaller wasn't allocating enough space to
memcpy the name. In order to take into account the size of a variable
array, it needs to be marked with the @end tag so that the
"extra_size" is added to the allocated memory.
It would be nice if the demarshaller would somehow fail if this wasn't
set explicitly, or do the right thing by default.
@end the name so that demarshaller
diff --git a/spice.proto b/spice.proto
index e3feffa..513fe87 100644
--- a/spice.proto
+++ b/spice.proto
@@ -225,7 +225,7 @@ channel MainChannel : BaseChannel {
message {
uint32 name_len;
- uint8 name[name_len];
+ uint8 name[name_len] @end;
} name;
message {
More information about the Spice-commits
mailing list