! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
Race condition in tumbler-registry.c
Status:
RESOLVED: FIXED
Product:
Tumbler
Component:
General

Comments

Description Štěpán Dalecký 2013-01-15 14:41:24 CET
Tumbler crashes every time it must generete new thumbnail.

tumbler-registry.c function tumbler_registry_get_thumbnailer_array

483:  if (!tumbler_thumbnailer_supports_location (lp->data, gfile))
on derefercing lp pointer.


I've started investigating the issue and I think it is a race condition, because adding usleep(1) before tumbler_thumbnailer_get_max_file_size call solved this issue.
Comment 1 Štěpán Dalecký 2013-01-15 14:43:04 CET
Problem is in git master and 0.1.27 versions. I didn't test any other version.
Comment 2 nevernow 2013-01-17 17:02:15 CET
I believe I can confirm the bug.

I tried building tumbler with full debug, but
Comment 3 nevernow 2013-01-17 17:04:34 CET
(In reply to comment #2)
> I believe I can confirm the bug.
> 
> I tried building tumbler with full debug, but

Sorry, keyboard accident. I wanted to add that:

- despite building with full debug, I can't get additional clues about the crash.

- I can't seem to reproduce the suggested usleep fix. Štěpán, could you share a patch? Thanks.
Comment 4 Štěpán Dalecký 2013-01-17 17:26:21 CET
Adding usleep(1) is not solution. It could only work for me. There is some race between threads and it should be solved by mutexes/semaphores etc.

If adding usleep(1) didn't help for you it means nothing. You could still downgrade or play with the code.
Comment 5 nevernow 2013-01-17 17:57:52 CET
I'm afraid my coding skills wouldn't be sufficient to play with the code in a useful way. For now, I downgraded.
Comment 6 Nick Schermer editbugs 2013-05-04 16:39:31 CEST
*** Bug 9852 has been marked as a duplicate of this bug. ***
Comment 7 Nick Schermer editbugs 2013-05-05 12:21:00 CEST
I cannot find a reason why this segfaults in the code, but I've put some additional debug messages and checks in the region that should help finding the cause.
Comment 8 Evangelos Foutras 2013-05-05 20:06:31 CEST
Created attachment 5023 
gdb backtrace

I started experiencing this issue with tumbler 0.1.28 (didn't happen with 0.1.27). It seems to be consistently reproducible.

I have attached a gdb backtrace of the crash.

OS: Arch Linux x86_64
Compiler: gcc version 4.8.0 20130502 (prerelease) (GCC)
Comment 9 Nick Schermer editbugs 2013-05-05 21:35:07 CEST
Sigh, 64 bit overflow. Fixed in a96c412.

Bug #9766

Reported by:
Štěpán Dalecký
Reported on: 2013-01-15
Last modified on: 2013-05-05
Duplicates (1):
  • 9852 tumbler-0.1.27: Segmentation fault at tumbler-registry.c:483 with

People

Assignee:
Jannis Pohlmann
CC List:
3 users

Version

Version:
unspecified

Attachments

gdb backtrace (3.56 KB, text/plain)
2013-05-05 20:06 CEST , Evangelos Foutras
no flags

Additional information