You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@thrift.apache.org by br...@apache.org on 2009/09/02 01:18:35 UTC

svn commit: r810303 - /incubator/thrift/trunk/lib/rb/ext/memory_buffer.c

Author: bryanduxbury
Date: Tue Sep  1 23:18:34 2009
New Revision: 810303

URL: http://svn.apache.org/viewvc?rev=810303&view=rev
Log:
THRIFT-572. rb: fix RSTRING for 1.9 compatibility

Use a macro compatible with Ruby 1.9.


Modified:
    incubator/thrift/trunk/lib/rb/ext/memory_buffer.c

Modified: incubator/thrift/trunk/lib/rb/ext/memory_buffer.c
URL: http://svn.apache.org/viewvc/incubator/thrift/trunk/lib/rb/ext/memory_buffer.c?rev=810303&r1=810302&r2=810303&view=diff
==============================================================================
--- incubator/thrift/trunk/lib/rb/ext/memory_buffer.c (original)
+++ incubator/thrift/trunk/lib/rb/ext/memory_buffer.c Tue Sep  1 23:18:34 2009
@@ -54,7 +54,7 @@
     index = 0;
   }
 
-  if (RSTRING(data)->len < length) {
+  if (RSTRING_LEN(data) < length) {
     rb_raise(rb_eEOFError, "Not enough bytes remain in memory buffer");
   }