aboutsummaryrefslogtreecommitdiff
path: root/ruby/ext/google/protobuf_c/map.c
diff options
context:
space:
mode:
Diffstat (limited to 'ruby/ext/google/protobuf_c/map.c')
-rw-r--r--ruby/ext/google/protobuf_c/map.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/ruby/ext/google/protobuf_c/map.c b/ruby/ext/google/protobuf_c/map.c
index 5043f395..92fc7286 100644
--- a/ruby/ext/google/protobuf_c/map.c
+++ b/ruby/ext/google/protobuf_c/map.c
@@ -167,10 +167,9 @@ void Map_free(void* _self) {
VALUE Map_alloc(VALUE klass) {
Map* self = ALLOC(Map);
- VALUE ret = TypedData_Wrap_Struct(klass, &Map_type, self);
memset(self, 0, sizeof(Map));
self->value_type_class = Qnil;
- return ret;
+ return TypedData_Wrap_Struct(klass, &Map_type, self);
}
static bool needs_typeclass(upb_fieldtype_t type) {