display crashes on thin images
I have filed an issue against ImageMagick: https://github.com/ImageMagick/ImageMagick/issues/6509
When I try to display the attached image , display crashes, the stacktrace indicates an endless recursive loop inside the PutSubImage function:
#5954 0x00007ffff72e4c7a in PutSubImage (dpy=0x555555571d90, d=71305664, gc=0x5555555bda50, image=0x555555629c50, req_xoffset=, req_yoffset=, x=0, y=0, req_width=2096928,
req_height=1, dest_bits_per_pixel=32, dest_scanline_pad=32) at ../../src/PutImage.c:920
#5955 0x00007ffff72e4c7a in PutSubImage (dpy=0x555555571d90, d=71305664, gc=0x5555555bda50, image=0x555555629c50, req_xoffset=, req_yoffset=, x=0, y=0, req_width=2096928,
req_height=1, dest_bits_per_pixel=32, dest_scanline_pad=32) at ../../src/PutImage.c:920
#5956 0x00007ffff72e4c7a in PutSubImage (dpy=0x555555571d90, d=71305664, gc=0x5555555bda50, image=0x555555629c50, req_xoffset=, req_yoffset=, x=0, y=0, req_width=2096928,
req_height=1, dest_bits_per_pixel=32, dest_scanline_pad=32) at ../../src/PutImage.c:920
#5957 0x00007ffff72e4c7a in PutSubImage (dpy=0x555555571d90, d=71305664, gc=0x5555555bda50, image=0x555555629c50, req_xoffset=, req_yoffset=, x=0, y=0, req_width=2096928,
req_height=1, dest_bits_per_pixel=32, dest_scanline_pad=32) at ../../src/PutImage.c:920![output](/uploads/6070967f4e7ff8cb465bac134935f531/output.png)
I guess that the problem is that due to the very wide and thing image (138240 x 16) display wants to scale it down for a thumbnail to the screensize, divides the height by some bigger factor, which then gets rounded down to 0 pixel, and then Xlib/libxcb crashes trying to resize or display the 0 pixel height image.