Project

General

Profile

Actions

Bug #12699

closed

Updated by nicolasnoble (Nicolas Noble) almost 9 years ago

Adding a Dockerfile that makes it easy to reproduce the problem, under Valgrind. The output of this Dockerfile gives the following report:
==1== Memcheck, a memory error detector ==1== Copyright (C) 2002-2015, and GNU GPL'd, by Julian Seward et al. ==1== Using Valgrind-3.11.0 and LibVEX; rerun with -h for copyright info ==1== Command: ruby repro.rb ==1== ==1== Use of uninitialised value of size 8 ==1== at 0x226120: rb_id_table_lookup (id_table.c:1516) ==1== by 0x26F2FB: lookup_method_table (vm_method.c:190) ==1== by 0x26F2FB: search_method (vm_method.c:701) ==1== by 0x26F2FB: method_entry_get_without_cache (vm_method.c:726) ==1== by 0x272E98: method_entry_get (vm_method.c:786) ==1== by 0x272E98: rb_callable_method_entry (vm_method.c:831) ==1== by 0x280C89: rb_call0 (vm_eval.c:343) ==1== by 0x2813F3: rb_call (vm_eval.c:637) ==1== by 0x2813F3: rb_funcall (vm_eval.c:835) ==1== by 0x2098F7: rb_obj_as_string (string.c:1254) ==1== by 0x1F5C17: ruby__sfvextra (sprintf.c:1375) ==1== by 0x1F6BA9: BSD_vfprintf (vsnprintf.c:836) ==1== by 0x1FD333: rb_enc_vsprintf (sprintf.c:1421) ==1== by 0x1FD333: rb_vsprintf (sprintf.c:1445) ==1== by 0x2FB26D: rb_raise (error.c:2060) ==1== by 0x2FC47D: rb_check_type (error.c:599) ==1== by 0x7195074: Map_index_set (in /usr/local/lib/ruby/gems/2.3.0/gems/google-protobuf-3.0.0.alpha.5.0.5.1-x86_64-linux/lib/google/2.3/protobuf_c.so) ==1== Uninitialised value was created by a client request ==1== at 0x14B118: gc_page_sweep (gc.c:3384) ==1== by 0x14B118: gc_sweep_step (gc.c:3559) ==1== by 0x150EC2: gc_sweep_rest (gc.c:3608) ==1== by 0x150EC2: gc_rest.part.63 (gc.c:6267) ==1== by 0x151FAC: gc_rest (gc.c:6161) ==1== by 0x151FAC: garbage_collect (gc.c:6154) ==1== by 0x152187: garbage_collect_with_gvl (gc.c:6394) ==1== by 0x152203: objspace_malloc_increase.isra.67 (gc.c:7558) ==1== by 0x1534BD: objspace_xmalloc (gc.c:7650) ==1== by 0x7192326: Message_alloc (in /usr/local/lib/ruby/gems/2.3.0/gems/google-protobuf-3.0.0.alpha.5.0.5.1-x86_64-linux/lib/google/2.3/protobuf_c.so) ==1== by 0x195D7F: rb_obj_alloc (object.c:1823) ==1== by 0x196070: rb_class_new_instance (object.c:1855) ==1== by 0x719668C: submsg_handler (in /usr/local/lib/ruby/gems/2.3.0/gems/google-protobuf-3.0.0.alpha.5.0.5.1-x86_64-linux/lib/google/2.3/protobuf_c.so) ==1== by 0x71B0DFF: run_decoder_vm (in /usr/local/lib/ruby/gems/2.3.0/gems/google-protobuf-3.0.0.alpha.5.0.5.1-x86_64-linux/lib/google/2.3/protobuf_c.so) ==1== by 0x719891F: Message_decode (in /usr/local/lib/ruby/gems/2.3.0/gems/google-protobuf-3.0.0.alpha.5.0.5.1-x86_64-linux/lib/google/2.3/protobuf_c.so) ==1== ==1== Invalid read of size 4 ==1== at 0x226120: rb_id_table_lookup (id_table.c:1516) ==1== by 0x26F2FB: lookup_method_table (vm_method.c:190) ==1== by 0x26F2FB: search_method (vm_method.c:701) ==1== by 0x26F2FB: method_entry_get_without_cache (vm_method.c:726) ==1== by 0x272E98: method_entry_get (vm_method.c:786) ==1== by 0x272E98: rb_callable_method_entry (vm_method.c:831) ==1== by 0x280C89: rb_call0 (vm_eval.c:343) ==1== by 0x2813F3: rb_call (vm_eval.c:637) ==1== by 0x2813F3: rb_funcall (vm_eval.c:835) ==1== by 0x2098F7: rb_obj_as_string (string.c:1254) ==1== by 0x1F5C17: ruby__sfvextra (sprintf.c:1375) ==1== by 0x1F6BA9: BSD_vfprintf (vsnprintf.c:836) ==1== by 0x1FD333: rb_enc_vsprintf (sprintf.c:1421) ==1== by 0x1FD333: rb_vsprintf (sprintf.c:1445) ==1== by 0x2FB26D: rb_raise (error.c:2060) ==1== by 0x2FC47D: rb_check_type (error.c:599) ==1== by 0x7195074: Map_index_set (in /usr/local/lib/ruby/gems/2.3.0/gems/google-protobuf-3.0.0.alpha.5.0.5.1-x86_64-linux/lib/google/2.3/protobuf_c.so) ==1== Address 0x0 is not stack'd, malloc'd or (recently) free'd ==1==

Updated by duerst (Martin Dürst) almost 9 years ago

  • Assignee deleted (core)

Updated by wanabe (_ wanabe) almost 9 years ago

  • Status changed from Open to Third Party's Issue

This issue have been cross-filed to google-protobuf by Nicolas Noble, original reporter.
https://.com/google/protobuf/issues/2004

This is fixed by the pull request of google-protobuf.
Looks like GC mark missing, as I see.
https://.com/google/protobuf/pull/2012

And "Updated packages are now available on RubyGems."
https://.com/google/protobuf/issues/2004#issuecomment-247202147

Actions

Also available in: Atom PDF

Like0
Like0Like0Like0