THRIFT-758. perl: incorrect deference in exception handling
authorBryan Duxbury <bryanduxbury@apache.org>
Thu, 2 Sep 2010 00:52:46 +0000 (00:52 +0000)
committerBryan Duxbury <bryanduxbury@apache.org>
Thu, 2 Sep 2010 00:52:46 +0000 (00:52 +0000)
Patch: Yann Kerherve

git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@991784 13f79535-47bb-0310-9956-ffa450edef68

lib/perl/lib/Thrift.pm

index fe0f8e7..3b7c57f 100644 (file)
@@ -93,11 +93,11 @@ sub read {
     my $ftype = 0;
     my $fid   = 0;
 
-    $xfer += $input->readStructBegin($fname);
+    $xfer += $input->readStructBegin(\$fname);
 
     while (1)
     {
-        $xfer += $input->readFieldBegin($fname, $ftype, $fid);
+        $xfer += $input->readFieldBegin(\$fname, \$ftype, \$fid);
         if ($ftype == TType::STOP) {
             last; next;
         }
@@ -107,7 +107,7 @@ sub read {
           /1/ && do{
 
               if ($ftype == TType::STRING) {
-                  $xfer += $input->readString($self->{message});
+                  $xfer += $input->readString(\$self->{message});
               } else {
                   $xfer += $input->skip($ftype);
               }
@@ -117,7 +117,7 @@ sub read {
 
           /2/ && do{
               if ($ftype == TType::I32) {
-                  $xfer += $input->readI32($self->{code});
+                  $xfer += $input->readI32(\$self->{code});
               } else {
                   $xfer += $input->skip($ftype);
               }