Code

Imported upstream version 1.3.8.
[pkg-rrdtool.git] / bindings / ruby / main.c
index 0e022e45d2722c17bcf313ae3080b4b4eb6ec1b5..bc314f6c5cfc3cc0217a37752773200255556ff0 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: main.c 1700 2008-12-08 16:07:27Z oetiker $
+/* $Id: main.c 1791 2009-04-14 13:55:29Z oetiker $
  * Substantial penalty for early withdrawal.
  */
 
@@ -32,7 +32,7 @@ string_arr string_arr_new(
     int       i;
 
     Check_Type(rb_strings, T_ARRAY);
-    a.len = RARRAY(rb_strings)->len + 1;
+    a.len = RARRAY_LEN(rb_strings) + 1;
 
     a.strings = malloc(a.len * sizeof(char *));
     a.strings[0] = "dummy"; /* first element is a dummy element */