git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@758071
13f79535-47bb-0310-9956-
ffa450edef68
return false;
}
if (parsedspec.type != type) {
- PyErr_SetString(PyExc_TypeError, "struct field had wrong type while reading");
- return false;
+ if (!skip(input, type)) {
+ PyErr_SetString(PyExc_TypeError, "struct field had wrong type while reading and can't be skipped");
+ return false;
+ } else {
+ continue;
+ }
}
fieldval = decode_val(input, parsedspec.type, parsedspec.typeargs);
struct VersioningTestV1 {
1: i32 begin_in_both,
+ 3: string old_string,
12: i32 end_in_both
}
def setUp(self):
self.v1obj = VersioningTestV1(
begin_in_both=12345,
+ old_string='aaa',
end_in_both=54321,
)