#1117980 gimp: Run gimp and immediately get... "free(): invalid pointer"

Package:
gimp
Source:
gimp
Description:
GNU Image Manipulation Program
Submitter:
Kingsley G. Morse Jr.
Date:
2025-10-21 03:53:02 UTC
Severity:
normal
#1117980#5
Date:
2025-10-13 06:30:01 UTC
From:
To:
Dear Maintainer,

Thanks for

    maintaining the cool package gimp and

    checking out my bug report.

I tried running gimp on bash's command line.

I expected gimp to display its graphical user
interface.

Unfortunately gimp immediately crashes with

    free(): invalid pointer

Here's a back trace from running gimp in gdb:

    (gdb) bt
    #0  0xb7fc7579 in __kernel_vsyscall ()
    #1  0xb609291f in __pthread_kill_implementation (threadid=threadid@entry=3028664320, signo=signo@entry=6,
        no_tid=no_tid@entry=0) at ./nptl/pthread_kill.c:43
    #2  0xb60929db in __pthread_kill_internal (threadid=3028664320, signo=6) at ./nptl/pthread_kill.c:89
    #3  0xb603bf31 in __GI_raise (sig=6) at ../sysdeps/posix/raise.c:26
    #4  0xb60232a2 in __GI_abort () at ./stdlib/abort.c:73
    #5  0xb60242ac in __libc_message_impl (fmt=<optimized out>) at ../sysdeps/posix/libc_fatal.c:134
    #6  0xb609dd0b in malloc_printerr (str=str@entry=0xb61c808a "free(): invalid pointer")
        at ./malloc/malloc.c:5829
    #7  0xb60a2b53 in _int_free_check (av=0xb6233760 <main_arena>, p=0xdd3830, size=<optimized out>)
        at ./malloc/malloc.c:4560
    #8  _int_free (av=0xb6233760 <main_arena>, p=0xdd3830, have_lock=0) at ./malloc/malloc.c:4692
    #9  __GI___libc_free (mem=0xdd3838) at ./malloc/malloc.c:3476
    #10 0xb79001c8 in g_free () from /lib/i386-linux-gnu/libglib-2.0.so.0
    #11 0x00544d6c in gimp_extension_load (extension=0xdd3970, error=0xbffff298)
        at ../app/core/gimpextension.c:415
    #12 0x004bc894 in gimp_extension_manager_search_directory (manager=manager@entry=0xdbd8f8,
        directory=<optimized out>, system_dir=system_dir@entry=1) at ../app/core/gimpextensionmanager.c:1039
    #13 0x004bce9f in gimp_extension_manager_initialize (manager=0xdbd8f8)
        at ../app/core/gimpextensionmanager.c:596
    #14 0x004a02dc in gimp_constructed (object=0xd78088) at ../app/core/gimp.c:319
    #15 0xb7a2fd85 in ?? () from /lib/i386-linux-gnu/libgobject-2.0.so.0
    #16 0xb7a326fc in g_object_new_valist () from /lib/i386-linux-gnu/libgobject-2.0.so.0
    #17 0xb7a32969 in g_object_new () from /lib/i386-linux-gnu/libgobject-2.0.so.0
    #18 0x004a0a77 in gimp_new (name=0xcbec70 "/usr/bin/gimp", session_name=0x0, default_folder=0x0,
        be_verbose=0, no_data=0, no_fonts=0, no_interface=0, use_shm=1, use_cpu_accel=1, console_messages=0,
        show_playground=0, show_debug_menu=0, stack_trace_mode=GIMP_STACK_TRACE_NEVER,
        pdb_compat_mode=GIMP_PDB_COMPAT_ON) at ../app/core/gimp.c:617
    #19 0x00671214 in app_run (full_prog_name=0xcbec70 "/usr/bin/gimp", filenames=0x0,
        alternate_system_gimprc=0x0, alternate_gimprc=0x0, session_name=0x0, batch_interpreter=0x0,
        batch_commands=0x0, quit=0, as_new=0, no_interface=0, no_data=0, no_fonts=0, no_splash=0,
        be_verbose=0, use_shm=1, use_cpu_accel=1, console_messages=0, use_debug_handler=0, show_playground=0,
        show_debug_menu=0, stack_trace_mode=GIMP_STACK_TRACE_NEVER, pdb_compat_mode=GIMP_PDB_COMPAT_ON,
        backtrace_file=0xca7170 "/home/kingsley/.config/GIMP/3.0/CrashLog/gimp-crash-1760078943.txt")
        at ../app/app.c:227
    #20 0x0049efd0 in main (argc=1, argv=<optimized out>) at ../app/main.c:793

Feel free to let me know if you happen to have
any suggestions.

Thanks,
Kingsley

#1117980#10
Date:
2025-10-18 20:31:54 UTC
From:
To:
I wondered if a corrupt configuration file in
~/.config/ crashed gimp.

So I ran it as a different user with different
configuration files.

Unfortunately, it still crashed when run as the
root user.

Here's what I saw

    root:~ gimp
    The connection is closed
    free(): invalid pointer
    Segmentation fault (core dumped)

So I expect something other than a corrupt
configuration file is crashing gimp.

So,
Kingsley

#1117980#15
Date:
2025-10-21 03:49:54 UTC
From:
To:
I humbly attach the output of a debugging tool
called "valgrind".

Valgrind automates finding software bugs related
to accessing memory.

Like free().

I'm no expert, but I happened to notice the "ERROR
SUMMARY" at the end of the attached log file
mentions

    gimpextension.c:415

Thanks,
Kingsley