#1025066 gimp: Segmentation fault when editing a text box on the picture

Package:
gimp
Source:
gimp
Description:
GNU Image Manipulation Program
Submitter:
Patrik Svestka
Date:
2022-12-29 12:03:04 UTC
Severity:
normal
#1025066#5
Date:
2022-11-29 13:54:25 UTC
From:
To:
Dear Maintainer,

   * What led up to the situation?
I have tried to edit a larger picutre with a text box, which was like 8th text box in the picture.

   * What exactly did you do (or not do) that was effective (or
Tried to edit the text in the text box.

   * What was the outcome of this action?
Segmentation fault of the Gimp.

   * What outcome did you expect instead?
Text being edited without the program crashing.

Here is the segfault report when GIMP crashed:

GIMP Crash Debug

<!-- Copy-paste this whole debug data to report to developers -->


```
GNU Image Manipulation Program version 2.10.32
git-describe: GIMP_2_10_32
Build: unknown rev 0 for linux
# C compiler #
    Using built-in specs.
    COLLECT_GCC=gcc
    COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/12/lto-wrapper
    OFFLOAD_TARGET_NAMES=nvptx-none:amdgcn-amdhsa
    OFFLOAD_TARGET_DEFAULT=1
    Target: x86_64-linux-gnu
    Configured with: ../src/configure -v --with-pkgversion='Debian 12.2.0-7' --with-bugurl=file:///usr/share/doc/gcc-12/README.Bugs --enable-languages=c,ada,c++,go,d,fortran,objc,obj-c++,m2 --prefix=/usr --with-gcc-major-version-only --program-suffix=-12 --program-prefix=x86_64-linux-gnu- --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --libdir=/usr/lib --enable-nls --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-vtable-verify --enable-plugin --enable-default-pie --with-system-zlib --enable-libphobos-checking=release --with-target-system-zlib=auto --enable-objc-gc=auto --enable-multiarch --disable-werror --enable-cet --with-arch-32=i686 --with-abi=m64 --with-multilib-list=m32,m64,mx32 --enable-multilib --with-tune=generic --enable-offload-targets=nvptx-none=/build/gcc-12-zpDQmA/gcc-12-12.2.0/debian/tmp-nvptx/usr,amdgcn-amdhsa=/build/gcc-12-zpDQmA/gcc-12-12.2.0/debian/tmp-gcn/usr --enable-offload-defaulted --without-cuda-driver --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu
    Thread model: posix
    Supported LTO compression algorithms: zlib zstd
    gcc version 12.2.0 (Debian 12.2.0-7)

# Libraries #
using babl version 0.1.98 (compiled against version 0.1.96)
using GEGL version 0.4.38 (compiled against version 0.4.38)
using GLib version 2.74.1 (compiled against version 2.74.1)
using GdkPixbuf version 2.42.10 (compiled against version 2.42.9)
using GTK+ version 2.24.33 (compiled against version 2.24.33)
using Pango version 1.50.10 (compiled against version 1.50.10)
using Fontconfig version 2.13.1 (compiled against version 2.13.1)
using Cairo version 1.16.0 (compiled against version 1.16.0)

```
```

# Stack traces obtained from PID 15417 - Thread 15417 #

[New LWP 15419]
[New LWP 15420]
[New LWP 15421]
[New LWP 15422]
[New LWP 15423]
[New LWP 15424]
[New LWP 15425]
[New LWP 15426]
[New LWP 15427]
[New LWP 15431]
[New LWP 84390]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
__GI___libc_read (nbytes=256, buf=0x7fff70ed1030, fd=18) at ../sysdeps/unix/sysv/linux/read.c:26
  Id   Target Id                                       Frame
* 1    Thread 0x7fbc196adec0 (LWP 15417) "gimp-2.10"   __GI___libc_read (nbytes=256, buf=0x7fff70ed1030, fd=18) at ../sysdeps/unix/sysv/linux/read.c:26
  2    Thread 0x7fbc18bff6c0 (LWP 15419) "worker"      syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
  3    Thread 0x7fbc183fe6c0 (LWP 15420) "worker"      syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
  4    Thread 0x7fbc17bfd6c0 (LWP 15421) "worker"      syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
  5    Thread 0x7fbc173fc6c0 (LWP 15422) "worker"      syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
  6    Thread 0x7fbc16bfb6c0 (LWP 15423) "worker"      syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
  7    Thread 0x7fbc163fa6c0 (LWP 15424) "worker"      syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
  8    Thread 0x7fbc15bf96c0 (LWP 15425) "worker"      syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
  9    Thread 0x7fbbf7e2c6c0 (LWP 15426) "gmain"       0x00007fbc1a1330af in __GI___poll (fds=0x55928cf8b560, nfds=2, timeout=-1) at ../sysdeps/unix/sysv/linux/poll.c:29
  10   Thread 0x7fbbf762b6c0 (LWP 15427) "gdbus"       0x00007fbc1a1330af in __GI___poll (fds=0x55928cfa04c0, nfds=3, timeout=-1) at ../sysdeps/unix/sysv/linux/poll.c:29
  11   Thread 0x7fbbe25ff6c0 (LWP 15431) "async"       syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
  12   Thread 0x7fbbd3fff6c0 (LWP 84390) "swap writer" syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38

Thread 12 (Thread 0x7fbbd3fff6c0 (LWP 84390) "swap writer"):
#0  syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
#1  0x00007fbc1a3a167f in g_cond_wait () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x00007fbc1a9277e9 in  () at /lib/x86_64-linux-gnu/libgegl-0.4.so.0
#3  0x00007fbc1a377d0d in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#4  0x00007fbc1a0bffd4 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
        ret = <optimized out>
        pd = <optimized out>
        unwind_buf = {cancel_jmp_buf = {{jmp_buf = {140444692379328, 5225349420116749960, -1152, 11, 140735087968720, 140444683988992, -5191651588537962872, -5189237987854504312}, mask_was_saved = 0}}, priv = {pad = {0x0, 0x0, 0x0, 0x0}, data = {prev = 0x0, cleanup = 0x0, canceltype = 0}}}
        not_first_call = <optimized out>
#5  0x00007fbc1a14066c in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 11 (Thread 0x7fbbe25ff6c0 (LWP 15431) "async"):
#0  syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
#1  0x00007fbc1a3a167f in g_cond_wait () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x000055928bbc7b88 in  ()
#3  0x00007fbc1a377d0d in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#4  0x00007fbc1a0bffd4 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
        ret = <optimized out>
        pd = <optimized out>
        unwind_buf = {cancel_jmp_buf = {{jmp_buf = {140444933551808, 5225349420116749960, -1152, 0, 140735087978944, 140444925161472, -5191543011764719992, -5189237987854504312}, mask_was_saved = 0}}, priv = {pad = {0x0, 0x0, 0x0, 0x0}, data = {prev = 0x0, cleanup = 0x0, canceltype = 0}}}
        not_first_call = <optimized out>
#5  0x00007fbc1a14066c in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 10 (Thread 0x7fbbf762b6c0 (LWP 15427) "gdbus"):
#0  0x00007fbc1a1330af in __GI___poll (fds=0x55928cfa04c0, nfds=3, timeout=-1) at ../sysdeps/unix/sysv/linux/poll.c:29
        sc_ret = -516
        sc_cancel_oldtype = 0
#1  0x00007fbc1a34d9ae in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x00007fbc1a34dcef in g_main_loop_run () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#3  0x00007fbc1a5e4296 in  () at /lib/x86_64-linux-gnu/libgio-2.0.so.0
#4  0x00007fbc1a377d0d in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#5  0x00007fbc1a0bffd4 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
        ret = <optimized out>
        pd = <optimized out>
        unwind_buf = {cancel_jmp_buf = {{jmp_buf = {140445286053568, 5225349420116749960, -1152, 11, 140735087979024, 140445277663232, -5191588957177368952, -5189237987854504312}, mask_was_saved = 0}}, priv = {pad = {0x0, 0x0, 0x0, 0x0}, data = {prev = 0x0, cleanup = 0x0, canceltype = 0}}}
        not_first_call = <optimized out>
#6  0x00007fbc1a14066c in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 9 (Thread 0x7fbbf7e2c6c0 (LWP 15426) "gmain"):
#0  0x00007fbc1a1330af in __GI___poll (fds=0x55928cf8b560, nfds=2, timeout=-1) at ../sysdeps/unix/sysv/linux/poll.c:29
        sc_ret = -516
        sc_cancel_oldtype = 0
#1  0x00007fbc1a34d9ae in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x00007fbc1a34dacc in g_main_context_iteration () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#3  0x00007fbc1a34db11 in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#4  0x00007fbc1a377d0d in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#5  0x00007fbc1a0bffd4 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
        ret = <optimized out>
        pd = <optimized out>
        unwind_buf = {cancel_jmp_buf = {{jmp_buf = {140445294446272, 5225349420116749960, -1152, 11, 140735087978640, 140445286055936, -5191590056152125816, -5189237987854504312}, mask_was_saved = 0}}, priv = {pad = {0x0, 0x0, 0x0, 0x0}, data = {prev = 0x0, cleanup = 0x0, canceltype = 0}}}
        not_first_call = <optimized out>
#6  0x00007fbc1a14066c in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 8 (Thread 0x7fbc15bf96c0 (LWP 15425) "worker"):
#0  syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
#1  0x00007fbc1a3a167f in g_cond_wait () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x00007fbc1a8eb353 in  () at /lib/x86_64-linux-gnu/libgegl-0.4.so.0
#3  0x00007fbc1a377d0d in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#4  0x00007fbc1a0bffd4 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
        ret = <optimized out>
        pd = <optimized out>
        unwind_buf = {cancel_jmp_buf = {{jmp_buf = {140445795456704, 5225349420116749960, -1152, 0, 140735087978800, 140445787066368, -5189271692398416248, -5189237987854504312}, mask_was_saved = 0}}, priv = {pad = {0x0, 0x0, 0x0, 0x0}, data = {prev = 0x0, cleanup = 0x0, canceltype = 0}}}
        not_first_call = <optimized out>
#5  0x00007fbc1a14066c in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 7 (Thread 0x7fbc163fa6c0 (LWP 15424) "worker"):
#0  syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
#1  0x00007fbc1a3a167f in g_cond_wait () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x00007fbc1a8eb353 in  () at /lib/x86_64-linux-gnu/libgegl-0.4.so.0
#3  0x00007fbc1a377d0d in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#4  0x00007fbc1a0bffd4 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
        ret = <optimized out>
        pd = <optimized out>
        unwind_buf = {cancel_jmp_buf = {{jmp_buf = {140445803849408, 5225349420116749960, -1152, 0, 140735087978800, 140445795459072, -5189263995280150904, -5189237987854504312}, mask_was_saved = 0}}, priv = {pad = {0x0, 0x0, 0x0, 0x0}, data = {prev = 0x0, cleanup = 0x0, canceltype = 0}}}
        not_first_call = <optimized out>
#5  0x00007fbc1a14066c in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 6 (Thread 0x7fbc16bfb6c0 (LWP 15423) "worker"):
#0  syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
#1  0x00007fbc1a3a167f in g_cond_wait () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x00007fbc1a8eb353 in  () at /lib/x86_64-linux-gnu/libgegl-0.4.so.0
#3  0x00007fbc1a377d0d in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#4  0x00007fbc1a0bffd4 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
        ret = <optimized out>
        pd = <optimized out>
        unwind_buf = {cancel_jmp_buf = {{jmp_buf = {140445812242112, 5225349420116749960, -1152, 0, 140735087978800, 140445803851776, -5189265096402391416, -5189237987854504312}, mask_was_saved = 0}}, priv = {pad = {0x0, 0x0, 0x0, 0x0}, data = {prev = 0x0, cleanup = 0x0, canceltype = 0}}}
        not_first_call = <optimized out>
#5  0x00007fbc1a14066c in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 5 (Thread 0x7fbc173fc6c0 (LWP 15422) "worker"):
#0  syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
#1  0x00007fbc1a3a167f in g_cond_wait () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x00007fbc1a8eb353 in  () at /lib/x86_64-linux-gnu/libgegl-0.4.so.0
#3  0x00007fbc1a377d0d in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#4  0x00007fbc1a0bffd4 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
        ret = <optimized out>
        pd = <optimized out>
        unwind_buf = {cancel_jmp_buf = {{jmp_buf = {140445820634816, 5225349420116749960, -1152, 0, 140735087978800, 140445812244480, -5189266195377148280, -5189237987854504312}, mask_was_saved = 0}}, priv = {pad = {0x0, 0x0, 0x0, 0x0}, data = {prev = 0x0, cleanup = 0x0, canceltype = 0}}}
        not_first_call = <optimized out>
#5  0x00007fbc1a14066c in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 4 (Thread 0x7fbc17bfd6c0 (LWP 15421) "worker"):
#0  syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
#1  0x00007fbc1a3a167f in g_cond_wait () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x00007fbc1a8eb353 in  () at /lib/x86_64-linux-gnu/libgegl-0.4.so.0
#3  0x00007fbc1a377d0d in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#4  0x00007fbc1a0bffd4 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
        ret = <optimized out>
        pd = <optimized out>
        unwind_buf = {cancel_jmp_buf = {{jmp_buf = {140445829027520, 5225349420116749960, -1152, 0, 140735087978800, 140445820637184, -5189267296499388792, -5189237987854504312}, mask_was_saved = 0}}, priv = {pad = {0x0, 0x0, 0x0, 0x0}, data = {prev = 0x0, cleanup = 0x0, canceltype = 0}}}
        not_first_call = <optimized out>
#5  0x00007fbc1a14066c in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 3 (Thread 0x7fbc183fe6c0 (LWP 15420) "worker"):
#0  syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
#1  0x00007fbc1a3a167f in g_cond_wait () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x00007fbc1a8eb353 in  () at /lib/x86_64-linux-gnu/libgegl-0.4.so.0
#3  0x00007fbc1a377d0d in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#4  0x00007fbc1a0bffd4 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
        ret = <optimized out>
        pd = <optimized out>
        unwind_buf = {cancel_jmp_buf = {{jmp_buf = {140445837420224, 5225349420116749960, -1152, 0, 140735087978800, 140445829029888, -5189242007195079032, -5189237987854504312}, mask_was_saved = 0}}, priv = {pad = {0x0, 0x0, 0x0, 0x0}, data = {prev = 0x0, cleanup = 0x0, canceltype = 0}}}
        not_first_call = <optimized out>
#5  0x00007fbc1a14066c in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 2 (Thread 0x7fbc18bff6c0 (LWP 15419) "worker"):
#0  syscall () at ../sysdeps/unix/sysv/linux/x86_64/syscall.S:38
#1  0x00007fbc1a3a167f in g_cond_wait () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x00007fbc1a8eb353 in  () at /lib/x86_64-linux-gnu/libgegl-0.4.so.0
#3  0x00007fbc1a377d0d in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#4  0x00007fbc1a0bffd4 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
        ret = <optimized out>
        pd = <optimized out>
        unwind_buf = {cancel_jmp_buf = {{jmp_buf = {140445845812928, 5225349420116749960, -1152, 0, 140735087978800, 140445837422592, -5189243108317319544, -5189237987854504312}, mask_was_saved = 0}}, priv = {pad = {0x0, 0x0, 0x0, 0x0}, data = {prev = 0x0, cleanup = 0x0, canceltype = 0}}}
        not_first_call = <optimized out>
#5  0x00007fbc1a14066c in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 1 (Thread 0x7fbc196adec0 (LWP 15417) "gimp-2.10"):
#0  __GI___libc_read (nbytes=256, buf=0x7fff70ed1030, fd=18) at ../sysdeps/unix/sysv/linux/read.c:26
        sc_ret = -512
        sc_cancel_oldtype = 0
        sc_ret = <optimized out>
#1  __GI___libc_read (fd=18, buf=0x7fff70ed1030, nbytes=256) at ../sysdeps/unix/sysv/linux/read.c:24
#2  0x00007fbc1adce55d in gimp_stack_trace_print () at /lib/x86_64-linux-gnu/libgimpbase-2.0.so.0
#3  0x000055928b8ced1f in  ()
#4  0x000055928b8cf0f8 in  ()
#5  0x000055928b8cf749 in  ()
#6  0x00007fbc1a072f90 in <signal handler called> () at /lib/x86_64-linux-gnu/libc.so.6
#7  0x00007fbc1a3819a0 in g_utf8_get_char () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#8  0x000055928b983ae0 in  ()
#9  0x00007fbc1a4463b0 in g_closure_invoke () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#10 0x00007fbc1a459076 in  () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#11 0x00007fbc1ae82aef in  () at /lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
#12 0x00007fbc1ae82fa1 in  () at /lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
#13 0x00007fbc1ae83444 in  () at /lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
#14 0x00007fbc1ae846ed in gtk_bindings_activate_event () at /lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
#15 0x000055928b984b62 in gimp_text_tool_editor_key_press ()
#16 0x000055928b9da24c in  ()
#17 0x000055928b9db1b9 in gimp_display_shell_canvas_tool_events ()
#18 0x00007fbc1af391ab in  () at /lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
#19 0x00007fbc1a4463b0 in g_closure_invoke () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#20 0x00007fbc1a459076 in  () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#21 0x00007fbc1a45f42d in g_signal_emit_valist () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#22 0x00007fbc1a45fdbf in g_signal_emit () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#23 0x00007fbc1b058fe4 in  () at /lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
#24 0x00007fbc1b06d248 in gtk_window_propagate_key_event () at /lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
#25 0x000055928baf54ea in  ()
#26 0x00007fbc1af391ab in  () at /lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
#27 0x00007fbc1a4463b0 in g_closure_invoke () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#28 0x00007fbc1a4591a5 in  () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#29 0x00007fbc1a45f42d in g_signal_emit_valist () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#30 0x00007fbc1a45fdbf in g_signal_emit () at /lib/x86_64-linux-gnu/libgobject-2.0.so.0
#31 0x00007fbc1b058fe4 in  () at /lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
#32 0x00007fbc1af3787c in gtk_propagate_event () at /lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
#33 0x00007fbc1af37c4b in gtk_main_do_event () at /lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
#34 0x00007fbc1b2f6afc in  () at /lib/x86_64-linux-gnu/libgdk-x11-2.0.so.0
#35 0x00007fbc1a34d7a9 in g_main_context_dispatch () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#36 0x00007fbc1a34da38 in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#37 0x00007fbc1a34dcef in g_main_loop_run () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#38 0x000055928b8ce4e1 in app_run ()
#39 0x000055928b8cdddf in main ()
[Inferior 1 (process 15417) detached]

```

#1025066#10
Date:
2022-12-12 11:03:03 UTC
From:
To:
Hello Patrik,
I just tried to collect some information and reconstruct
the given backtrace with some line information [1].

This gimp_text_tool_move_cursor leads to this upstream
bug reports [2]. Unfortunately all closed without result.

There are a few more upstream reports with g_utf8_get_char [3],
all with some non-latin characters, but all seem not
reproducible.

@Patrik, can you provide the text you wanted to enter?
Had it contained some "special" e.g. non-latin characters?
When you try it again, does it crash again?
If yes, maybe describe exactly the actions shortly before the crash?

Kind regards,
Bernhard



[1]
    #7  0x00007fbc1a3819a0 in g_utf8_get_char at ../../../glib/gutf8.c:336 at libglib-2.0.so.0
    #8  0x000055928b983ae0 in gimp_text_tool_move_cursor at ./app/tools/gimptexttool-editor.c:900 at gimp
    #9  0x00007fbc1a4463b0 in in g_closure_invoke at ../../../gobject/gclosure.c:832 at libgobject-2.0.so.0
    #10 0x00007fbc1a459076 in signal_emit_unlocked_R at ../../../gobject/gsignal.c:3796 at libgobject-2.0.so.0

https://sources.debian.org/src/glib2.0/2.74.2-1/glib/gutf8.c/#L336
    335   gunichar result;
    336   unsigned char c = (unsigned char) *p;
    337

https://sources.debian.org/src/gimp/2.10.32-1/app/tools/gimptexttool-editor.c/#L900
    899                   if (new_index != -1 && new_index != G_MAXINT &&
    900                       g_utf8_get_char (text + new_index) == word_joiner)
    901                     {


[2]
https://gitlab.gnome.org/GNOME/gimp/-/issues/7019
https://gitlab.gnome.org/GNOME/gimp/-/issues/4408
https://gitlab.gnome.org/GNOME/gimp/-/issues/3960
https://gitlab.gnome.org/GNOME/gimp/-/issues/3643
https://gitlab.gnome.org/GNOME/gimp/-/issues/3460

[3]
https://gitlab.gnome.org/GNOME/gimp/-/issues/6468
https://gitlab.gnome.org/GNOME/gimp/-/issues/6704
https://gitlab.gnome.org/GNOME/gimp/-/issues/6794

#1025066#15
Date:
2022-12-16 07:34:26 UTC
From:
To:
Hello Bernhard,

I think the text was the following [containing Czech characters]:

"Ahoj, já se jmenuji Sam a ty se jmenuješ jak?  Máš takový krásný
kožíšek, že Ti v něm musí být teď pěkně teploučko.  Ta bačkůrka v které
ležíš má stejnou barvu jako já."

When I tried again it did not crash as I have finished editing the
whole picture.

The actions taken: I have placed a text tool field over a picture
(backround) which has created its own layer (with text tool icon left
of the layer's name) where I have entered the text.  After the text
tool field was created I started typing the text and then it crashed.

Best regards,

Patrik

#1025066#20
Date:
2022-12-29 12:00:55 UTC
From:
To:
Dear Maintainer,

I can reproduce the segmentation fault with simple steps and no
non-latin characters on the text box. Steps:
 - Open GIMP
 - File > New
 - Select the Text Tool
 - Place it anywhere and hit any letter

I get a segmentation fault every time.

Here is the debug data spat out by GIMP. I'm not familiar with this,
it doesn't look exactly the same as that reported by Patrik. Please
let me know if I should open a new bug report instead. Please find
attached the output on the terminal when running the steps above, in
case it helps.


<!-- Copy-paste this whole debug data to report to developers -->


```
GNU Image Manipulation Program version 2.10.32
git-describe: GIMP_2_10_32
Build: unknown rev 0 for linux
# C compiler #
	Using built-in specs.
	COLLECT_GCC=gcc
	COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/12/lto-wrapper
	OFFLOAD_TARGET_NAMES=nvptx-none:amdgcn-amdhsa
	OFFLOAD_TARGET_DEFAULT=1
	Target: x86_64-linux-gnu
	Configured with: ../src/configure -v --with-pkgversion='Debian 12.2.0-7' --with-bugurl=file:///usr/share/doc/gcc-12/README.Bugs --enable-languages=c,ada,c++,go,d,fortran,objc,obj-c++,m2 --prefix=/usr --with-gcc-major-version-only --program-suffix=-12 --program-prefix=x86_64-linux-gnu- --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --libdir=/usr/lib --enable-nls --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-vtable-verify --enable-plugin --enable-default-pie --with-system-zlib --enable-libphobos-checking=release --with-target-system-zlib=auto --enable-objc-gc=auto --enable-multiarch --disable-werror --enable-cet --with-arch-32=i686 --with-abi=m64 --with-multilib-list=m32,m64,mx32 --enable-multilib --with-tune=generic --enable-offload-targets=nvptx-none=/build/gcc-12-zpDQmA/gcc-12-12.2.0/debian/tmp-nvptx/usr,amdgcn-amdhsa=/build/gcc-12-zpDQmA/gcc-12-12.2.0/debian/tmp-gcn/usr --enable-offload-defaulted --without-cuda-driver --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu
	Thread model: posix
	Supported LTO compression algorithms: zlib zstd
	gcc version 12.2.0 (Debian 12.2.0-7)

# Libraries #
using babl version 0.1.96 (compiled against version 0.1.96)
using GEGL version 0.4.38 (compiled against version 0.4.38)
using GLib version 2.73.3 (compiled against version 2.74.1)
using GdkPixbuf version 2.42.9 (compiled against version 2.42.9)
using GTK+ version 2.24.33 (compiled against version 2.24.33)
using Pango version 1.50.9 (compiled against version 1.50.10)
using Fontconfig version 2.13.1 (compiled against version 2.13.1)
using Cairo version 1.16.0 (compiled against version 1.16.0)

```
```
/lib/x86_64-linux-gnu/libgimpbase-2.0.so.0(gimp_stack_trace_print+0x3e8)[0x7fb23fbe8658]
gimp(+0xdcd1f)[0x560c9cff1d1f]
gimp(+0xdd0f8)[0x560c9cff20f8]
gimp(+0xdd749)[0x560c9cff2749]
/lib/x86_64-linux-gnu/libc.so.6(+0x3bf90)[0x7fb23eeb8f90]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(+0x25103)[0x7fb23f298103]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(+0x1b6d8)[0x7fb23f28e6d8]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(+0x1bf5a)[0x7fb23f28ef5a]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(g_object_new_with_properties+0x194)[0x7fb23f2903f4]
gimp(gimp_image_undo_push+0x19d)[0x560c9d36fadd]
gimp(gimp_image_undo_push_text_layer+0x104)[0x560c9d3726b4]
gimp(gimp_text_tool_apply+0x103)[0x560c9d0a1f13]
gimp(+0x18eaa7)[0x560c9d0a3aa7]
gimp(+0x18ece2)[0x560c9d0a3ce2]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(g_closure_invoke+0x160)[0x7fb23f289500]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(+0x29b36)[0x7fb23f29cb36]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(g_signal_emit_valist+0xf35)[0x7fb23f2a36b5]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(g_signal_emit+0x8f)[0x7fb23f2a387f]
gimp(+0x191465)[0x560c9d0a6465]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(g_closure_invoke+0x160)[0x7fb23f289500]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(+0x29b36)[0x7fb23f29cb36]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(g_signal_emit_valist+0xf35)[0x7fb23f2a36b5]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(g_signal_emit_by_name+0x1f8)[0x7fb23f2a3a98]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(g_closure_invoke+0x160)[0x7fb23f289500]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(+0x29b36)[0x7fb23f29cb36]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(g_signal_emit_valist+0xf35)[0x7fb23f2a36b5]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(g_signal_emit_by_name+0x1f8)[0x7fb23f2a3a98]
/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0(+0x11f030)[0x7fb23fd1f030]
/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0(+0x11f613)[0x7fb23fd1f613]
gimp(gimp_text_tool_editor_key_press+0x98)[0x560c9d0a7ac8]
gimp(+0x1e824c)[0x560c9d0fd24c]
gimp(gimp_display_shell_canvas_tool_events+0x79)[0x560c9d0fe1b9]
/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0(+0x1391ab)[0x7fb23fd391ab]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(g_closure_invoke+0x160)[0x7fb23f289500]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(+0x29b36)[0x7fb23f29cb36]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(g_signal_emit_valist+0x76d)[0x7fb23f2a2eed]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(g_signal_emit+0x8f)[0x7fb23f2a387f]
/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0(+0x258fe4)[0x7fb23fe58fe4]
/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0(gtk_window_propagate_key_event+0xa8)[0x7fb23fe6d248]
gimp(+0x3034ea)[0x560c9d2184ea]
/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0(+0x1391ab)[0x7fb23fd391ab]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(g_closure_invoke+0x160)[0x7fb23f289500]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(+0x29c65)[0x7fb23f29cc65]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(g_signal_emit_valist+0x76d)[0x7fb23f2a2eed]
/lib/x86_64-linux-gnu/libgobject-2.0.so.0(g_signal_emit+0x8f)[0x7fb23f2a387f]
/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0(+0x258fe4)[0x7fb23fe58fe4]
/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0(gtk_propagate_event+0x14c)[0x7fb23fd3787c]
/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0(gtk_main_do_event+0x36b)[0x7fb23fd37c4b]
/lib/x86_64-linux-gnu/libgdk-x11-2.0.so.0(+0x5fafc)[0x7fb240132afc]
/lib/x86_64-linux-gnu/libglib-2.0.so.0(g_main_context_dispatch+0x299)[0x7fb23f191729]
/lib/x86_64-linux-gnu/libglib-2.0.so.0(+0x549b8)[0x7fb23f1919b8]
/lib/x86_64-linux-gnu/libglib-2.0.so.0(g_main_loop_run+0x6f)[0x7fb23f191c6f]
gimp(app_run+0x351)[0x560c9cff14e1]
gimp(main+0x35f)[0x560c9cff0ddf]
/lib/x86_64-linux-gnu/libc.so.6(+0x2718a)[0x7fb23eea418a]
/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0x85)[0x7fb23eea4245]
gimp(_start+0x21)[0x560c9cff0f61]

```