Code Review
/
common
/
thrift.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
review
|
tree
raw
|
patch
| inline |
side by side
(parent:
cd9f200
)
THRIFT-840. perl: Perl protocol handler could be more robust against unrecognised...
author
Bryan Duxbury
<bryanduxbury@apache.org>
Thu, 2 Sep 2010 00:24:50 +0000
(
00:24
+0000)
committer
Bryan Duxbury
<bryanduxbury@apache.org>
Thu, 2 Sep 2010 00:24:50 +0000
(
00:24
+0000)
This patch causes the protocol to throw an exception when it sees an unrecognized type instead of silently doing nothing.
Patch: Conrad Hughes
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@991778
13f79535
-47bb-0310-9956-
ffa450edef68
lib/perl/lib/Thrift/Protocol.pm
patch
|
blob
|
history
diff --git
a/lib/perl/lib/Thrift/Protocol.pm
b/lib/perl/lib/Thrift/Protocol.pm
index
034711f
..
e2801fe
100644
(file)
--- a/
lib/perl/lib/Thrift/Protocol.pm
+++ b/
lib/perl/lib/Thrift/Protocol.pm
@@
-399,8
+399,7
@@
sub skip
return $result;
}
-
- return 0;
+ die new Thrift::TException("Type $type not recognised --- corrupt data?");
}
@@
-511,8
+510,7
@@
sub skipBinary
return $result;
}
- return 0;
-
+ die new Thrift::TException("Type $type not recognised --- corrupt data?");
}
#