Page MenuHomePhabricator

Invalid Argument on spin_trylock
Closed, ResolvedPublic

Description

As always on OpenBSD with EFL 1.18 and e21.

To reproduce:

Open enlightenment_filemanager -> Click on an icon for a text file -> Move mouse and stop on icon -> Wait for preview to show -> try to scroll down in the preview of the text file -> BOOM!!!

invalid_argument on spin_trylock ... this then spins forever spewing out these errors.

netstar created this task.Jul 15 2016, 6:42 AM
Current language:  auto; currently asm
  3 thread 1003593  0x00000d0dbb9a255a in _thread_sys_select () at <stdin>:2
  2 thread 1000145  0x00000d0dbb95f20a in _thread_sys_write () at <stdin>:2
* 1 thread 1026941  0x00000d0dbb9c101a in _thread_sys___thrsleep () at <stdin>:2
#0  0x00000d0dbb9c101a in _thread_sys___thrsleep () at <stdin>:2
#1  0x00000d0d1ee04c43 in *_libpthread_pthread_cond_wait (condp=Variable "condp" is not available.
) at /usr/src/lib/librthread/rthread_sync.c:513
#2  0x00000d0d3377c957 in eina_condition_wait (cond=0xd0d33c7ee00) at eina_inline_lock_posix.x:441
#3  0x00000d0d3377c754 in evas_thread_worker_func (data=0x0, thread=14348841232440)
    at lib/evas/common/evas_thread_render.c:76
#4  0x00000d0cf07abaed in _eina_internal_call (context=0xd0d8631b700) at lib/eina/eina_thread.c:150
#5  0x00000d0d1ee064ee in _rthread_start (v=Variable "v" is not available.
) at /usr/src/lib/librthread/rthread.c:115
#6  0x00000d0dbb9d208b in __tfork_thread () at /usr/src/lib/libc/arch/amd64/sys/tfork_thread.S:75
#7  0x0000000000000000 in ?? ()
[Switching to thread 2 (thread 1000145)]#0  0x00000d0dbb95f20a in _thread_sys_write () at <stdin>:2
2	<stdin>: No such file or directory.
	in <stdin>
#0  0x00000d0dbb95f20a in _thread_sys_write () at <stdin>:2
#1  0x00000d0dbb94ebb7 in *_libc_write_cancel (fd=Variable "fd" is not available.
) at /usr/src/lib/libc/sys/w_write.c:27
#2  0x00000d0dbb9c7eb6 in __swrite (cookie=0xd0dbbdf0878, 
    buf=0x7f7ffffc69f0 "EINA ERROR: 'Invalid argument' on spin_trylock 0xd0d16036678\n\177", n=Variable "n" is not available.
) at /usr/src/lib/libc/stdio/stdio.c:66
#3  0x00000d0dbb95a64f in __sflush (fp=0x7f7ffffc66e0) at /usr/src/lib/libc/stdio/fflush.c:80
#4  0x00000d0dbb97f652 in __vfprintf (fp=0xd0dbbdf0878, fmt0=0xd0d3d4dfd35 "EINA ERROR: '%s' on %s %p\n", ap=Variable "ap" is not available.
) at /usr/src/lib/libc/stdio/vfprintf.c:140
#5  0x00000d0dbb982348 in *_libc_vfprintf (fp=0xd0dbbdf0878, fmt0=0xd0d3d4dfd35 "EINA ERROR: '%s' on %s %p\n", 
    ap=0x7f7ffffc6ee0) at /usr/src/lib/libc/stdio/vfprintf.c:262
#6  0x00000d0dbb998e1c in *_libc_printf (fmt=Variable "fmt" is not available.
) at /usr/src/lib/libc/stdio/printf.c:44
#7  0x00000d0d3d3d5641 in eina_spinlock_take (spinlock=0xd0d16036678) at eina_inline_lock_posix.x:761
#8  0x00000d0d3d3d6228 in ecore_thread_cancel (thread=0xd0d16036600) at lib/ecore/ecore_thread.c:672
#9  0x00000d0ad516d0ba in _e_wid_del_hook () from /opt/bin/enlightenment
#10 0x00000d0ad5165998 in _e_smart_del () from /opt/bin/enlightenment
#11 0x00000d0d3366e7a9 in evas_object_smart_del (eo_obj=0x4000008810000882)
    at lib/evas/canvas/evas_object_smart.c:1084
#12 0x00000d0d33659b16 in _efl_canvas_object_eo_base_destructor (eo_obj=0x4000008810000882, obj=0xd0cf5679080)
    at lib/evas/canvas/evas_object_main.c:821
#13 0x00000d0d4d37583f in eo_destructor (obj=0x4000008810000882) at eo_base.eo.c:90
#14 0x00000d0d4d36ba93 in _eo_del_internal (file=0xd0d4d477bc4 "lib/eo/eo_private.h", line=334, 
    obj=0xd0cf5679000) at eo_private.h:232
#15 0x00000d0d4d36ba05 in _eo_unref (obj=0xd0cf5679000) at eo_private.h:334
#16 0x00000d0d4d36bf16 in _eo_call_end (call=0x7f7ffffc72d0) at lib/eo/eo.c:473
#17 0x00000d0d4d375558 in eo_del (obj=0x4000008810000882) at eo_base.eo.c:78
#18 0x00000d0d336594c4 in evas_object_del (eo_obj=0x4000008810000882) at lib/evas/canvas/evas_object_main.c:739
#19 0x00000d0d0965e881 in _elm_widget_efl_canvas_group_group_del (obj=0x40000087e000087f, sd=0xd0db5ded620)
    at lib/elementary/elm_widget.c:454
#20 0x00000d0d33671298 in efl_canvas_group_del (obj=0xc0000087e000087f) at efl_canvas_group.eo.c:72
#21 0x00000d0d094c86cf in _elm_box_efl_canvas_group_group_del (obj=0x40000087e000087f, sd=0xd0db5ded760)
    at lib/elementary/elm_box.c:425
#22 0x00000d0d33671298 in efl_canvas_group_del (obj=0x40000087e000087f) at efl_canvas_group.eo.c:72
#23 0x00000d0d3366e7b4 in evas_object_smart_del (eo_obj=0x40000087e000087f)
    at lib/evas/canvas/evas_object_smart.c:1086
#24 0x00000d0d33659b16 in _efl_canvas_object_eo_base_destructor (eo_obj=0x40000087e000087f, obj=0xd0db5ded480)
    at lib/evas/canvas/evas_object_main.c:821
#25 0x00000d0d4d37583f in eo_destructor (obj=0xc0000087e000087f) at eo_base.eo.c:90
#26 0x00000d0d0966e88a in _elm_widget_eo_base_destructor (obj=0x40000087e000087f, sd=0xd0db5ded620)
    at lib/elementary/elm_widget.c:5836
#27 0x00000d0d4d37583f in eo_destructor (obj=0x40000087e000087f) at eo_base.eo.c:90
#28 0x00000d0d4d36ba93 in _eo_del_internal (file=0xd0d4d477bc4 "lib/eo/eo_private.h", line=334, 
    obj=0xd0db5ded400) at eo_private.h:232
#29 0x00000d0d4d36ba05 in _eo_unref (obj=0xd0db5ded400) at eo_private.h:334
#30 0x00000d0d4d36bf16 in _eo_call_end (call=0x7f7ffffc7710) at lib/eo/eo.c:473
#31 0x00000d0d4d375558 in eo_del (obj=0x40000087e000087f) at eo_base.eo.c:78
#32 0x00000d0d336594c4 in evas_object_del (eo_obj=0x40000087e000087f) at lib/evas/canvas/evas_object_main.c:739
#33 0x00000d0ad51659e7 in _e_smart_del () from /opt/bin/enlightenment
#34 0x00000d0d3366e7a9 in evas_object_smart_del (eo_obj=0x40000087d000087e)
    at lib/evas/canvas/evas_object_smart.c:1084
#35 0x00000d0d33659b16 in _efl_canvas_object_eo_base_destructor (eo_obj=0x40000087d000087e, obj=0xd0db5ded080)
    at lib/evas/canvas/evas_object_main.c:821
#36 0x00000d0d4d37583f in eo_destructor (obj=0x40000087d000087e) at eo_base.eo.c:90
#37 0x00000d0d4d36ba93 in _eo_del_internal (file=0xd0d4d477bc4 "lib/eo/eo_private.h", line=334, 
    obj=0xd0db5ded000) at eo_private.h:232
#38 0x00000d0d4d36ba05 in _eo_unref (obj=0xd0db5ded000) at eo_private.h:334
#39 0x00000d0d4d36bf16 in _eo_call_end (call=0x7f7ffffc79d0) at lib/eo/eo.c:473
#40 0x00000d0d4d375558 in eo_del (obj=0x40000087d000087e) at eo_base.eo.c:78
#41 0x00000d0d336594c4 in evas_object_del (eo_obj=0x40000087d000087e) at lib/evas/canvas/evas_object_main.c:739
#42 0x00000d0ad507cd3f in _e_comp_object_util_del () from /opt/bin/enlightenment
#43 0x00000d0d33627d9b in _eo_evas_object_cb (data=0xd0dac8abe80, event=0x7f7ffffc7b30)
    at lib/evas/canvas/evas_callbacks.c:92
#44 0x00000d0d4d373360 in _eo_base_event_callback_call (obj_id=0x400000ab90000aba, pd=0xd0cec850050, 
    desc=0xd0d33a486d0, event_info=0x0) at lib/eo/eo_base_class.c:1176
#45 0x00000d0d4d376518 in eo_event_callback_call (obj=0x400000ab90000aba, desc=0xd0d33a486d0, event_info=0x0)
    at eo_base.eo.c:142
#46 0x00000d0d33628682 in evas_object_event_callback_call (eo_obj=0x400000ab90000aba, obj=0xd0cec850080, 
    type=EVAS_CALLBACK_DEL, event_info=0x0, event_id=15458, eo_event_desc=0x0, eo_event_info=0x0)
    at lib/evas/canvas/evas_callbacks.c:297
#47 0x00000d0d33659771 in _efl_canvas_object_eo_base_destructor (eo_obj=0x400000ab90000aba, obj=0xd0cec850080)
    at lib/evas/canvas/evas_object_main.c:764
#48 0x00000d0d4d37583f in eo_destructor (obj=0xc00000ab90000aba) at eo_base.eo.c:90
#49 0x00000d0da94eec72 in _edje_object_eo_base_destructor (obj=0x400000ab90000aba, class_data=0xd0cec850230)
    at lib/edje/edje_smart.c:58
#50 0x00000d0d4d37583f in eo_destructor (obj=0x400000ab90000aba) at eo_base.eo.c:90
#51 0x00000d0d4d36ba93 in _eo_del_internal (file=0xd0d4d477bc4 "lib/eo/eo_private.h", line=334, 
    obj=0xd0cec850000) at eo_private.h:232
#52 0x00000d0d4d36ba05 in _eo_unref (obj=0xd0cec850000) at eo_private.h:334
#53 0x00000d0d4d36bf16 in _eo_call_end (call=0x7f7ffffc7ed0) at lib/eo/eo.c:473
#54 0x00000d0d4d375558 in eo_del (obj=0x400000ab90000aba) at eo_base.eo.c:78
#55 0x00000d0d336594c4 in evas_object_del (eo_obj=0x400000ab90000aba) at lib/evas/canvas/evas_object_main.c:739
#56 0x00000d0d33659382 in evas_object_unref (eo_obj=0x400000ab90000aba)
    at lib/evas/canvas/evas_object_main.c:702
#57 0x00000d0ad507d01f in _e_comp_object_util_done_defer () from /opt/bin/enlightenment
#58 0x00000d0da94e4a76 in edje_match_callback_exec_check_finals (ssp=0xd0d45e4af80, matches=0xd0dab4e9ec0, 
    signal_states=0xd0d21c94000, source_states=0xd0d4ee34198, sig=0xd0da629c43c "e,action,hide,done", 
    source=0xd0cf08da88a "e", ed=0xd0cec850230, prop=0 '\0') at lib/edje/edje_match.c:556
#59 0x00000d0da94e50ba in edje_match_callback_exec (ssp=0xd0d45e4af80, matches=0xd0dab4e9ec0, 
    sig=0xd0da629c43c "e,action,hide,done", source=0xd0cf08da88a "e", ed=0xd0cec850230, prop=0 '\0')
    at lib/edje/edje_match.c:711
#60 0x00000d0da94ec5af in _edje_emit_cb (ed=0xd0cec850230, sig=0xd0da629c43c "e,action,hide,done", 
    src=0xd0cf08da88a "e", data=0x0, prop=0 '\0') at lib/edje/edje_program.c:1461
#61 0x00000d0da94ec421 in _edje_emit_handle (ed=0xd0cec850230, sig=0xd0da629c43c "e,action,hide,done", 
    src=0xd0cf08da88a "e", sdata=0x0, prop=0 '\0') at lib/edje/edje_program.c:1413
#62 0x00000d0da94e6bd8 in _edje_message_process (em=0xd0d7bb815c0) at lib/edje/edje_message_queue.c:684
#63 0x00000d0da94e6faf in _edje_message_queue_process () at lib/edje/edje_message_queue.c:787
#64 0x00000d0da94e5c1f in _edje_job (data=0x0) at lib/edje/edje_message_queue.c:154
#65 0x00000d0d3d3cc1d9 in _ecore_job_event_handler (data=0x0, type=15, ev=0xd0dab4e9720)
    at lib/ecore/ecore_job.c:98
#66 0x00000d0d3d3c6767 in _ecore_call_handler_cb (func=0xd0d3d3cc1ac <_ecore_job_event_handler>, data=0x0, 
    type=15, event=0xd0dab4e9720) at ecore_private.h:317
#67 0x00000d0d3d3c61fd in _ecore_event_call () at lib/ecore/ecore_events.c:518
#68 0x00000d0d3d3ce36d in _ecore_main_loop_iterate_internal (once_only=0) at lib/ecore/ecore_main.c:2344
#69 0x00000d0d3d3cc751 in ecore_main_loop_begin () at lib/ecore/ecore_main.c:1286
#70 0x00000d0ad503f853 in main () from /opt/bin/enlightenment
[Switching to thread 3 (thread 1003593)]#0  0x00000d0dbb9a255a in _thread_sys_select () at <stdin>:2
2	<stdin>: No such file or directory.
	in <stdin>
#0  0x00000d0dbb9a255a in _thread_sys_select () at <stdin>:2
#1  0x00000d0dbb9cba49 in *_libc_select_cancel (nfds=Variable "nfds" is not available.
) at /usr/src/lib/libc/sys/w_select.c:28
#2  0x00000d0d3d3c393b in _timer_tick_core (data=0x0, thread=0xd0cfab98900) at lib/ecore/ecore_anim.c:127
#3  0x00000d0d3d3d589e in _ecore_direct_worker (work=0xd0cfab98900) at lib/ecore/ecore_thread.c:425
#4  0x00000d0cf07abaed in _eina_internal_call (context=0xd0d1da06540) at lib/eina/eina_thread.c:150
#5  0x00000d0d1ee064ee in _rthread_start (v=Variable "v" is not available.
) at /usr/src/lib/librthread/rthread.c:115
#6  0x00000d0dbb9d208b in __tfork_thread () at /usr/src/lib/libc/arch/amd64/sys/tfork_thread.S:75
#7  0x0000000000000000 in ?? ()
The program is running.  Quit anyway (and detach it)? (y or n) Detaching from program: /opt/bin/enlightenment, process 145
netstar triaged this task as High priority.Jul 15 2016, 6:47 AM

This is a good one because finally a reliable way to reproduce an otherwise EXTREMELY intermittent problem.

I am trying to reproduce this problem under linux, but failing so far. Mostly because the preview has always vanished for me before I could get to it and do anything. What is the way of getting inside the preview before it disapear to be able to scroll down. Also could you recompile enlightenment with debug symbol so I can figure out from which file does the crash come from.

This probably isn't reproducible on Linux.

I was debugging ecore_con earlier and managed to reproduce the same issue:

/* start of comment
   int res = ecore_con_url_init();

*/
   url = ecore_con_url_new("blah");

   exit (0);

If the initialisation doesn't work and/or isn't tested for this happens:

EINA ERROR: 'Invalid argument' on spin_trylock 0x16eba4a67978
EINA ERROR: 'Invalid argument' on spin_trylock 0x16eba4a67978
EINA ERROR: 'Invalid argument' on spin_trylock 0x16eba4a67978
EINA ERROR: 'Invalid argument' on spin_trylock 0x16eba4a67978
EINA ERROR: 'Invalid argument' on spin_trylock 0x16eba4a67978
EINA ERROR: 'Invalid argument' on spin_trylock 0x16eba4a67978
EINA ERROR: 'Invalid argument' on spin_trylock 0x16eba4a67978
EINA ERROR: 'Invalid argument' on spin_trylock 0x16eba4a67978
EINA ERROR: 'Invalid argument' on spin_trylock 0x16eba4a67978
EINA ERROR: 'Invalid argument' on spin_trylock 0x16eba4a67978
EINA ERROR: 'Invalid argument' on spin_trylock 0x16eba4a67978
EINA ERROR: 'Invalid argument' on spin_trylock 0x16eba4a67978

So my suspicion is parts of EFL aren't being initialised properly and/or the result not being tested so it's assumed it can't fail (which it can), and THIS is what is causing this behaviour...I hope this makes sense to you.

Here we go:

netstar reopened this task as Open.Jul 18 2016, 5:23 PM

This happens now.

Preview has no content then window dissapears and efm freezes and e too.

netstar closed this task as Resolved.Jul 18 2016, 5:25 PM

Seems okay, sorry!