Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exit pcmanfm but process remains - race condition in thumbnail loading? #58

Open
jimrustle opened this issue Aug 14, 2020 · 0 comments
Open

Comments

@jimrustle
Copy link

pcmanfm 1.3.1, with libfm 1.3.1 on debian bullseye/sid, linux 5.7.0-2-amd64

I noticed that pcmanfm would sometimes not terminate or exit after closing the window. i.e., multiple pcmanfm processes would appear in htop and unable to be terminated via SIGTERM (SIGKILL required). This issue only seems to appear when I load a directory with a significant number of image files or pdf files, and then close the window while the thumbnails for those files are loading. If I wait (10-15 seconds) for all of the thumbnails to finish loading, then the pcmanfm process exits cleanly and there is no issue.

I ran gdb and these traces are from a process that does not exit.

Thread 1 "pcmanfm" received signal SIGINT, Interrupt.
syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
38      ../sysdeps/unix/sysv/linux/x86_64/syscall.S: No such file or directory.
─── Assembly ───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
 0x00007ffff7271a79  ? cmp    $0xfffffffffffff001,%rax
 0x00007ffff7271a7f  ? jae    0x7ffff7271a82 <syscall+34>
 0x00007ffff7271a81  ? retq   
 0x00007ffff7271a82  ? mov    0xc53e7(%rip),%rcx        # 0x7ffff7336e70
 0x00007ffff7271a89  ? neg    %eax
 0x00007ffff7271a8b  ? mov    %eax,%fs:(%rcx)
 0x00007ffff7271a8e  ? or     $0xffffffffffffffff,%rax
 0x00007ffff7271a92  ? retq   
 0x00007ffff7271a93  ? nopw   %cs:0x0(%rax,%rax,1)
 0x00007ffff7271a9d  ? nopl   (%rax)
─── Registers ──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
     rax 0xfffffffffffffe00      rbx 0x000000000000006e        rcx 0x00007ffff7271a79     rdx 0x000000000000006e     rsi 0x0000000000000080
     rdi 0x00007ffff7708a28      rbp 0x00007ffff7708a30        rsp 0x00007fffffffe0c8      r8 0x0000000000000000      r9 0x00007ffff7708a30
     r10 0x0000000000000000      r11 0x0000000000000246        r12 0x00007ffff7708a28     r13 0x0000000000000000     r14 0x0000000000000000
     r15 0x0000000000000000      rip 0x00007ffff7271a79     eflags [ PF ZF IF ]            cs 0x00000033              ss 0x0000002b        
      ds 0x00000000               es 0x00000000                 fs 0x00000000              gs 0x00000000        
─── Source ─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
Cannot display "syscall.S"
─── Stack ──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
[0] from 0x00007ffff7271a79 in syscall at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
[1] from 0x00007ffff73fc8ef in g_cond_wait
[2] from 0x00007ffff76e882f in _fm_thumbnail_loader_finalize+175 at base/fm-thumbnail-loader.c:793
[3] from 0x00007ffff76d1bbb in fm_finalize+107 at fm.c:163
[4] from 0x000055555556a741 in main+513 at pcmanfm.c:307
─── Threads ────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
[14] id 377742 name loader from 0x00007ffff7271a79 in syscall at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
[5] id 377733 name pool-pcmanfm from 0x00007ffff7271a79 in syscall at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
[3] id 377730 name gdbus from 0x00007ffff726c4bf in __GI___poll+79 at ../sysdeps/unix/sysv/linux/poll.c:29
[2] id 377729 name gmain from 0x00007ffff726c4bf in __GI___poll+79 at ../sysdeps/unix/sysv/linux/poll.c:29
[1] id 377727 name pcmanfm from 0x00007ffff7271a79 in syscall at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
>>> thread 5
[Switching to thread 5 (Thread 0x7fffef7fe700 (LWP 377733))]
#0  syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
38      in ../sysdeps/unix/sysv/linux/x86_64/syscall.S
>>> bt
#0  syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
#1  0x00007ffff73fca12 in g_cond_wait_until () at /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x00007ffff73815c1 in  () at /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#3  0x00007ffff7381bb2 in g_async_queue_timeout_pop () at /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#4  0x00007ffff73d9e29 in  () at /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#5  0x00007ffff73d951d in  () at /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#6  0x00007ffff7346ea7 in start_thread (arg=<optimized out>) at pthread_create.c:477
#7  0x00007ffff7276eaf in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
>>> thread 14
[Switching to thread 14 (Thread 0x7fffeffff700 (LWP 377742))]
#0  syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
38      in ../sysdeps/unix/sysv/linux/x86_64/syscall.S
>>> bt
#0  syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
#1  0x00007ffff73fc8ef in g_cond_wait () at /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x00007ffff76e763f in run_thumbnailer (thumbnailer=thumbnailer@entry=0x7fffe800d6a0, task=task@entry=0x555555816f80, output_file=<optimized out>, size=size@entry=128) at base/fm-thumbnail-loader.c:1127
#3  0x00007ffff76e7ee5 in generate_thumbnails_with_thumbnailers (task=0x555555816f80) at base/fm-thumbnail-loader.c:1155
#4  generate_thumbnails (task=0x555555816f80) at base/fm-thumbnail-loader.c:815
#5  load_thumbnail_thread (user_data=<optimized out>) at base/fm-thumbnail-loader.c:488
#6  0x00007ffff73d951d in  () at /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#7  0x00007ffff7346ea7 in start_thread (arg=<optimized out>) at pthread_create.c:477
#8  0x00007ffff7276eaf in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant