From: Tobias Brunner Date: Mon, 10 Dec 2012 08:41:32 +0000 (+0100) Subject: rb_cvar_set() takes three arguments in Ruby 1.9 X-Git-Tag: 5.0.2dr4~111 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6a25122bfca4917f38092f3f0c4fddeb8798fb39;p=thirdparty%2Fstrongswan.git rb_cvar_set() takes three arguments in Ruby 1.9 --- diff --git a/src/dumm/ext/dumm.c b/src/dumm/ext/dumm.c index 7c7d65acd0..1f047679c1 100644 --- a/src/dumm/ext/dumm.c +++ b/src/dumm/ext/dumm.c @@ -141,7 +141,11 @@ static VALUE guest_hash(VALUE class) if (!rb_cvar_defined(class, id)) { VALUE hash = guest_hash_create(class); +#ifdef RB_CVAR_SET_4_ARGS rb_cvar_set(class, id, hash, 0); +#else + rb_cvar_set(class, id, hash); +#endif return hash; } return rb_cvar_get(class, id);