diff options
Diffstat (limited to 'src/plugins/ruby/weechat-ruby-api.c')
-rw-r--r-- | src/plugins/ruby/weechat-ruby-api.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/plugins/ruby/weechat-ruby-api.c b/src/plugins/ruby/weechat-ruby-api.c index 4db4d3326..ec6ba2e65 100644 --- a/src/plugins/ruby/weechat-ruby-api.c +++ b/src/plugins/ruby/weechat-ruby-api.c @@ -77,6 +77,8 @@ return INT2FIX (__int) #define API_RETURN_LONG(__long) \ return LONG2NUM (__long) +#define API_RETURN_LONGLONG(__longlong) \ + return LL2NUM (__longlong) /* @@ -454,9 +456,9 @@ weechat_ruby_api_string_parse_size (VALUE class, VALUE size) char *c_size; unsigned long long value; - API_INIT_FUNC(1, "string_parse_size", API_RETURN_LONG(0)); + API_INIT_FUNC(1, "string_parse_size", API_RETURN_LONGLONG(0)); if (NIL_P (size)) - API_WRONG_ARGS(API_RETURN_LONG(0)); + API_WRONG_ARGS(API_RETURN_LONGLONG(0)); Check_Type (size, T_STRING); @@ -464,7 +466,7 @@ weechat_ruby_api_string_parse_size (VALUE class, VALUE size) value = weechat_string_parse_size (c_size); - API_RETURN_LONG(value); + API_RETURN_LONGLONG(value); } static VALUE |