Segfault in pg_get_pg_encname_as_rb_encoding()

Issue #120 on hold
Michael Granger
repo owner created an issue



Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x803e510c0 (LWP 100219)] 0x0000000800d447f6 in strcmp () from /lib/

0 0x0000000800d447f6 in strcmp () from /lib/

1 0x0000000806f05a63 in pg_get_pg_encname_as_rb_encoding (pg_encname=0x7031797 <Error reading address 0x7031797: Bad address>) at ../../../../ext/pg.c:141

2 0x0000000806f05a00 in pg_get_pg_encoding_as_rb_encoding (enc_id=0) at ../../../../ext/pg.c:141

3 0x0000000806f05ae5 in pg_conn_enc_get (conn=0x806d57400) at ../../../../ext/pg.c:141

4 0x0000000806f0ca59 in pg_new_result (result=0x806d6d0e0, conn=0x806d57400) at ../../../../ext/pg_result.c:28

5 0x0000000806f0ac8d in pgconn_get_last_result (self=34394991800) at ruby.h:1335

6 0x0000000806f0ad1e in pgconn_async_exec (argc=1, argv=0x806c00688, self=34394991800) at ruby.h:1335

7 0x0000000000514bb1 in call_cfunc (func=0x806f0acaa <pgconn_async_exec>, recv=34394991800, len=-1, argc=1, argv=0x806c00688) at ruby.h:1320

8 0x00000000005154ee in vm_call_cfunc (th=0x80489a800, reg_cfp=0x806cfee20, num=1, recv=34394991800, blockptr=0x0, me=0x806e878e0) at ruby.h:1320

9 0x0000000000515bb2 in vm_call_method (th=0x80489a800, cfp=0x806cfee20, num=1, blockptr=0x0, flag=8, id=80240, me=0x806e878e0, recv=34394991800) at ruby.h:1320

10 0x000000000051b453 in vm_exec_core (th=0x80489a800, initial=0) at ruby.h:1320

11 0x000000000052872d in vm_exec (th=0x80489a800) at ruby.h:1320

12 0x000000000052714c in invoke_block_from_c (th=0x80489a800, block=0x806e43e30, self=34421829480, argc=1, argv=0x806c00500, blockptr=0x0, cref=0x0) at ruby.h:1320

13 0x0000000000527380 in rb_vm_invoke_proc (th=0x80489a800, proc=0x806e43e30, self=34421829480, argc=1, argv=0x806c00500, blockptr=0x0) at ruby.h:1320

14 0x0000000000418687 in proc_call (argc=1, argv=0x806c00500, procval=34421829080) at ruby.h:1320

15 0x0000000000514bb1 in call_cfunc (func=0x4185d6 <proc_call>, recv=34421829080, len=-1, argc=1, argv=0x806c00500) at ruby.h:1320

16 0x00000000005154ee in vm_call_cfunc (th=0x80489a800, reg_cfp=0x806cff1e8, num=1, recv=34421829080, blockptr=0x0, me=0x801110880) at ruby.h:1320

17 0x0000000000515bb2 in vm_call_method (th=0x80489a800, cfp=0x806cff1e8, num=1, blockptr=0x0, flag=0, id=6008, me=0x801110880, recv=34421829080) at ruby.h:1320

18 0x000000000051b453 in vm_exec_core (th=0x80489a800, initial=0) at ruby.h:1320

19 0x000000000052872d in vm_exec (th=0x80489a800) at ruby.h:1320

20 0x00000000005221b6 in vm_call0 (th=0x80489a800, recv=34394742440, id=424, argc=0, argv=0x0, me=0x801dc5f40) at ruby.h:1320

21 0x000000000052293c in rb_call0 (recv=34394742440, mid=424, argc=0, argv=0x0, scope=CALL_FCALL, self=6) at ruby.h:1320

22 0x00000000005230b5 in rb_call (recv=34394742440, mid=424, argc=0, argv=0x0, scope=CALL_FCALL) at ruby.h:1320

23 0x0000000000524110 in iterate_method (obj=140737484118480) at ruby.h:1320

24 0x0000000000523f19 in rb_iterate (it_proc=0x5240cc <iterate_method>, data1=140737484118480, bl_proc=0x5616e8 <collect_i>, data2=34394889480) at ruby.h:1320

25 0x000000000052416d in rb_block_call (obj=34394742440, mid=424, argc=0, argv=0x0, bl_proc=0x5616e8 <collect_i>, data2=34394889480) at ruby.h:1320

26 0x00000000005617e1 in enum_collect (obj=34394742440) at ruby.h:1335

27 0x0000000000514bc8 in call_cfunc (func=0x56176f <enum_collect>, recv=34394742440, len=0, argc=0, argv=0x806c002b0) at ruby.h:1320

28 0x00000000005154ee in vm_call_cfunc (th=0x80489a800, reg_cfp=0x806cff818, num=0, recv=34394742440, blockptr=0x806d1c200, me=0x800f28b40) at ruby.h:1320

29 0x0000000000515bb2 in vm_call_method (th=0x80489a800, cfp=0x806cff818, num=0, blockptr=0x806d1c200, flag=136, id=1568, me=0x800f28b40, recv=34394742440) at ruby.h:1320

30 0x000000000051b6c7 in vm_exec_core (th=0x80489a800, initial=0) at ruby.h:1320

31 0x000000000052872d in vm_exec (th=0x80489a800) at ruby.h:1320

32 0x00000000005221b6 in vm_call0 (th=0x80489a800, recv=34394723400, id=456, argc=1, argv=0x806c00178, me=0x804945540) at ruby.h:1320

33 0x000000000052293c in rb_call0 (recv=34394723400, mid=456, argc=1, argv=0x806c00178, scope=CALL_FCALL, self=6) at ruby.h:1320

34 0x00000000005230b5 in rb_call (recv=34394723400, mid=456, argc=1, argv=0x806c00178, scope=CALL_FCALL) at ruby.h:1320

35 0x0000000000523868 in rb_funcall2 (recv=34394723400, mid=456, argc=1, argv=0x806c00178) at ruby.h:1320

36 0x00000000004174a4 in rb_obj_call_init (obj=34394723400, argc=1, argv=0x806c00178) at ruby.h:1320

37 0x000000000044cd38 in rb_class_new_instance (argc=1, argv=0x806c00178, klass=34419524640) at ruby.h:1320

38 0x0000000000514bb1 in call_cfunc (func=0x44cd00 <rb_class_new_instance>, recv=34419524640, len=-1, argc=1, argv=0x806c00178) at ruby.h:1320

39 0x00000000005154ee in vm_call_cfunc (th=0x80489a800, reg_cfp=0x806cffa80, num=1, recv=34419524640, blockptr=0x0, me=0x800f281c0) at ruby.h:1320

40 0x0000000000515bb2 in vm_call_method (th=0x80489a800, cfp=0x806cffa80, num=1, blockptr=0x0, flag=0, id=1000, me=0x800f281c0, recv=34419524640) at ruby.h:1320

41 0x000000000051b453 in vm_exec_core (th=0x80489a800, initial=0) at ruby.h:1320

42 0x000000000052872d in vm_exec (th=0x80489a800) at ruby.h:1320

43 0x000000000052714c in invoke_block_from_c (th=0x80489a800, block=0x806e44470, self=34422277480, argc=1, argv=0x806c00130, blockptr=0x0, cref=0x0) at ruby.h:1320

44 0x0000000000527380 in rb_vm_invoke_proc (th=0x80489a800, proc=0x806e44470, self=34422277480, argc=1, argv=0x806c00130, blockptr=0x0) at ruby.h:1320

45 0x0000000000418687 in proc_call (argc=1, argv=0x806c00130, procval=34422271280) at ruby.h:1320

46 0x0000000000514bb1 in call_cfunc (func=0x4185d6 <proc_call>, recv=34422271280, len=-1, argc=1, argv=0x806c00130) at ruby.h:1320

47 0x00000000005154ee in vm_call_cfunc (th=0x80489a800, reg_cfp=0x806cffb88, num=1, recv=34422271280, blockptr=0x0, me=0x801110880) at ruby.h:1320

48 0x0000000000515bb2 in vm_call_method (th=0x80489a800, cfp=0x806cffb88, num=1, blockptr=0x0, flag=0, id=6008, me=0x801110880, recv=34422271280) at ruby.h:1320

49 0x000000000051b453 in vm_exec_core (th=0x80489a800, initial=0) at ruby.h:1320

50 0x000000000052872d in vm_exec (th=0x80489a800) at ruby.h:1320

51 0x000000000052714c in invoke_block_from_c (th=0x80489a800, block=0x806cffd10, self=34422277480, argc=1, argv=0x7fffffbf8bd8, blockptr=0x0, cref=0x0) at ruby.h:1320

52 0x000000000052727b in vm_yield (th=0x80489a800, argc=1, argv=0x7fffffbf8bd8) at ruby.h:1320

53 0x0000000000523a9e in rb_yield_0 (argc=1, argv=0x7fffffbf8bd8) at ruby.h:1320

54 0x0000000000523ad8 in rb_yield (val=34422271200) at ruby.h:1320

55 0x000000000053f516 in rb_ary_each (array=34382584760) at ruby.h:1320

56 0x0000000000514bc8 in call_cfunc (func=0x53f48a <rb_ary_each>, recv=34382584760, len=0, argc=0, argv=0x806c000c8) at ruby.h:1320

57 0x00000000005154ee in vm_call_cfunc (th=0x80489a800, reg_cfp=0x806cffce8, num=0, recv=34382584760, blockptr=0x806cffd10, me=0x800fd54e0) at ruby.h:1320

58 0x0000000000515bb2 in vm_call_method (th=0x80489a800, cfp=0x806cffce8, num=0, blockptr=0x806cffd10, flag=0, id=424, me=0x800fd54e0, recv=34382584760) at ruby.h:1320

59 0x000000000051b453 in vm_exec_core (th=0x80489a800, initial=0) at ruby.h:1320

60 0x000000000052872d in vm_exec (th=0x80489a800) at ruby.h:1320

61 0x000000000052714c in invoke_block_from_c (th=0x80489a800, block=0x806cffe70, self=34422277480, argc=0, argv=0x0, blockptr=0x0, cref=0x0) at ruby.h:1320

62 0x000000000052727b in vm_yield (th=0x80489a800, argc=0, argv=0x0) at ruby.h:1320

63 0x0000000000523a9e in rb_yield_0 (argc=0, argv=0x0) at ruby.h:1320

64 0x0000000000523d67 in loop_i () at ruby.h:1320

65 0x0000000000416b73 in rb_rescue2 (b_proc=0x523d54 <loop_i>, data1=0, r_proc=0, data2=0) at ruby.h:1320

66 0x0000000000523dd8 in rb_f_loop (self=34422277480) at ruby.h:1320

67 0x0000000000514bc8 in call_cfunc (func=0x523d69 <rb_f_loop>, recv=34422277480, len=0, argc=0, argv=0x806c00068) at ruby.h:1320

68 0x00000000005154ee in vm_call_cfunc (th=0x80489a800, reg_cfp=0x806cffe48, num=0, recv=34422277480, blockptr=0x806cffe70, me=0x800fa7e80) at ruby.h:1320

69 0x0000000000515bb2 in vm_call_method (th=0x80489a800, cfp=0x806cffe48, num=0, blockptr=0x806cffe70, flag=8, id=2896, me=0x800fa7e80, recv=34422277480) at ruby.h:1320

70 0x000000000051b453 in vm_exec_core (th=0x80489a800, initial=0) at ruby.h:1320

71 0x000000000052872d in vm_exec (th=0x80489a800) at ruby.h:1320

72 0x000000000052714c in invoke_block_from_c (th=0x80489a800, block=0x803004e70, self=34376029440, argc=0, argv=0x802212ab0, blockptr=0x0, cref=0x0) at ruby.h:1320

73 0x0000000000527380 in rb_vm_invoke_proc (th=0x80489a800, proc=0x803004e70, self=34376029440, argc=0, argv=0x802212ab0, blockptr=0x0) at ruby.h:1320

74 0x000000000052db95 in thread_start_func_2 (th=0x80489a800, stack_start=0x7fffffbfb000) at ruby.h:1335

75 0x000000000052c94f in thread_start_func_1 (th_ptr=0x80489a800) at ruby.h:1335

76 0x0000000800838a88 in pthread_getprio () from /lib/

77 0x0000000000000000 in ?? ()

Error accessing memory address 0x7fffffbfb000: Bad address. }}}

Encoding of the database is SQL_ASCII.

Comments (7)

  1. Log in to comment