Closed jimtjames closed 4 months ago
I see a similar situation when running ain-imager. This is present when running from the repository and sources. I noticed this with a recent OS update. Before this, ain-imager worked fine from the repository.
OS: KDE Neon 5.27 Kernel: 5.19.0-46-generic i3-9100F GeForce GT710
I will check to see what is wrong. Can you please run it with valgrind and provide me the output?
valgrind ./ain_imager_src/ain_imager
Thank you! Rumen
On Fri, Jul 14, 2023 at 12:51 AM astrokor @.***> wrote:
I see a similar situation when running ain-imager. This is present when running from the repository and sources. I noticed this with a recent OS update. Before this, ain-imager worked fine from the repository.
OS: KDE Neon 5.27 Kernel: 5.19.0-46-generic i3-9100F GeForce GT710
[image: image] https://user-images.githubusercontent.com/139509209/253415026-72dced7e-f325-4b61-8b3c-8e0d22d06246.png
— Reply to this email directly, view it on GitHub https://github.com/indigo-astronomy/indigo_imager/issues/12#issuecomment-1634965814, or unsubscribe https://github.com/notifications/unsubscribe-auth/AE5EZBMEXQ4UPUHQQ3SVFJTXQBUUJANCNFSM6AAAAAAZSML2AU . You are receiving this because you are subscribed to this thread.Message ID: @.***>
Sorry, I can not reproduce the problem on fedora 38 with KDE 5.27.6. Most likely you are not building it correctly... Please give me the output from valgrind it may help...
Operating System: KDE neon 5.27 KDE Plasma Version: 5.27.5 KDE Frameworks Version: 5.107.0 Qt Version: 5.15.10 Kernel Version: 5.19.0-43-generic (64-bit) Graphics Platform: X11 Processors: 6 × Intel® Core™ i5-9400 CPU @ 2.90GHz Memory: 31.0 GiB of RAM Graphics Processor: Mesa Intel® UHD Graphics 630
neon@neon:~$ valgrind ain_imager
==4004== Memcheck, a memory error detector
==4004== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
==4004== Using Valgrind-3.18.1 and LibVEX; rerun with -h for copyright info
==4004== Command: ain_imager
==4004==
==4004== Invalid read of size 8
==4004== at 0x40286C8: strncmp (strcmp.S:172)
==4004== by 0x400668D: is_dst (dl-load.c:216)
==4004== by 0x400810E: _dl_dst_count (dl-load.c:253)
==4004== by 0x400810E: expand_dynamic_string_token (dl-load.c:395)
==4004== by 0x40082B7: fillin_rpath.isra.0 (dl-load.c:483)
==4004== by 0x4008602: decompose_rpath (dl-load.c:654)
==4004== by 0x400ABF5: cache_rpath (dl-load.c:696)
==4004== by 0x400ABF5: cache_rpath (dl-load.c:677)
==4004== by 0x400ABF5: _dl_map_object (dl-load.c:2165)
==4004== by 0x4003494: openaux (dl-deps.c:64)
==4004== by 0x66B3C27: _dl_catch_exception (dl-error-skeleton.c:208)
==4004== by 0x4003C7B: _dl_map_object_deps (dl-deps.c:248)
==4004== by 0x400EA0E: dl_open_worker_begin (dl-open.c:592)
==4004== by 0x66B3C27: _dl_catch_exception (dl-error-skeleton.c:208)
==4004== by 0x400DF99: dl_open_worker (dl-open.c:782)
==4004== Address 0xb1ae029 is 9 bytes inside a block of size 15 alloc'd
==4004== at 0x4848899: malloc (in /usr/libexec/valgrind/vgpreload_memcheck-amd64-linux.so)
==4004== by 0x40271FF: malloc (rtld-malloc.h:56)
==4004== by 0x40271FF: strdup (strdup.c:42)
==4004== by 0x4008594: decompose_rpath (dl-load.c:629)
==4004== by 0x400ABF5: cache_rpath (dl-load.c:696)
==4004== by 0x400ABF5: cache_rpath (dl-load.c:677)
==4004== by 0x400ABF5: _dl_map_object (dl-load.c:2165)
==4004== by 0x4003494: openaux (dl-deps.c:64)
==4004== by 0x66B3C27: _dl_catch_exception (dl-error-skeleton.c:208)
==4004== by 0x4003C7B: _dl_map_object_deps (dl-deps.c:248)
==4004== by 0x400EA0E: dl_open_worker_begin (dl-open.c:592)
==4004== by 0x66B3C27: _dl_catch_exception (dl-error-skeleton.c:208)
==4004== by 0x400DF99: dl_open_worker (dl-open.c:782)
==4004== by 0x66B3C27: _dl_catch_exception (dl-error-skeleton.c:208)
==4004== by 0x400E34D: _dl_open (dl-open.c:883)
==4004==
==4004== Invalid read of size 8
==4004== at 0x40286C8: strncmp (strcmp.S:172)
==4004== by 0x400668D: is_dst (dl-load.c:216)
==4004== by 0x4007F79: _dl_dst_substitute (dl-load.c:295)
==4004== by 0x40082B7: fillin_rpath.isra.0 (dl-load.c:483)
==4004== by 0x4008602: decompose_rpath (dl-load.c:654)
==4004== by 0x400ABF5: cache_rpath (dl-load.c:696)
==4004== by 0x400ABF5: cache_rpath (dl-load.c:677)
==4004== by 0x400ABF5: _dl_map_object (dl-load.c:2165)
==4004== by 0x4003494: openaux (dl-deps.c:64)
==4004== by 0x66B3C27: _dl_catch_exception (dl-error-skeleton.c:208)
==4004== by 0x4003C7B: _dl_map_object_deps (dl-deps.c:248)
==4004== by 0x400EA0E: dl_open_worker_begin (dl-open.c:592)
==4004== by 0x66B3C27: _dl_catch_exception (dl-error-skeleton.c:208)
==4004== by 0x400DF99: dl_open_worker (dl-open.c:782)
==4004== Address 0xb1ae029 is 9 bytes inside a block of size 15 alloc'd
==4004== at 0x4848899: malloc (in /usr/libexec/valgrind/vgpreload_memcheck-amd64-linux.so)
==4004== by 0x40271FF: malloc (rtld-malloc.h:56)
==4004== by 0x40271FF: strdup (strdup.c:42)
==4004== by 0x4008594: decompose_rpath (dl-load.c:629)
==4004== by 0x400ABF5: cache_rpath (dl-load.c:696)
==4004== by 0x400ABF5: cache_rpath (dl-load.c:677)
==4004== by 0x400ABF5: _dl_map_object (dl-load.c:2165)
==4004== by 0x4003494: openaux (dl-deps.c:64)
==4004== by 0x66B3C27: _dl_catch_exception (dl-error-skeleton.c:208)
==4004== by 0x4003C7B: _dl_map_object_deps (dl-deps.c:248)
==4004== by 0x400EA0E: dl_open_worker_begin (dl-open.c:592)
==4004== by 0x66B3C27: _dl_catch_exception (dl-error-skeleton.c:208)
==4004== by 0x400DF99: dl_open_worker (dl-open.c:782)
==4004== by 0x66B3C27: _dl_catch_exception (dl-error-skeleton.c:208)
==4004== by 0x400E34D: _dl_open (dl-open.c:883)
==4004==
==4004== Invalid write of size 4
==4004== at 0x2F7978: LibRaw::LibRaw(unsigned int) (in /usr/bin/ain_imager)
==4004== by 0x1CA5D4AE: ??? (in /usr/lib/x86_64-linux-gnu/qt5/plugins/imageformats/kimg_raw.so)
==4004== by 0x1CA5D725: ??? (in /usr/lib/x86_64-linux-gnu/qt5/plugins/imageformats/kimg_raw.so)
==4004== by 0x5531A1C: ??? (in /usr/lib/x86_64-linux-gnu/libQt5Gui.so.5.15.10)
==4004== by 0x5534343: ??? (in /usr/lib/x86_64-linux-gnu/libQt5Gui.so.5.15.10)
==4004== by 0x55358E7: QImageReader::read(QImage) (in /usr/lib/x86_64-linux-gnu/libQt5Gui.so.5.15.10)
==4004== by 0x5535AD8: QImageReader::read() (in /usr/lib/x86_64-linux-gnu/libQt5Gui.so.5.15.10)
==4004== by 0x555354C: QRasterPlatformPixmap::fromData(unsigned char const, unsigned int, char const, QFlags
Are you using the libraw verion provided in the Ain source code? you should run build_libs.sh it will build the provided third-party libraries for you and use them to link against them.
If you have libraw installed already it may be causing the problems. Ain uses a bit differently compiled libraw to work.
Weirdly enough, I got it to work now (albeit I am now on Fedora 38 instead of 37). I completely deleted and uninstalled all of my old INDIGO directories and libraries, re-cloned and then recompiled. It launches fine now. I guess some library must have changed in the Fedora repos.
Thanks for looking into this.
Are you using the libraw verion provided in the Ain source code? you should run build_libs.sh it will build the provided third-party libraries for you and use them to link against them.
If you have libraw installed already it may be causing the problems. Ain uses a bit differently compiled libraw to work.
libraw 0.20.2 is installed in the system.
For KDEneon I used the installation from the PPA, not source. kimageformat-plugins does not allow launching the ain-imager, kimageformat-plugins 5.108.0 is installed in the system. I downgraded this version to 5.92.0, and ain-imager with a successful launch.
I hope my report was helpful.
Rumen, thanks for your guidance! Good project and good work.
Regards, Ruslan.
I am also getting similar errors. Ain-imager fails to launch. I have not build the code. Just installed binaries. It is running fine on my other machine running Kubuntu 22.04
Operating System: Ubuntu 23.04 KDE Plasma Version: 5.27.4 KDE Frameworks Version: 5.104.0 Qt Version: 5.15.8 Kernel Version: 6.2.0-26-generic (64-bit) Graphics Platform: X11 Processors: 6 × Intel® Core™ i5-8500T CPU @ 2.10GHz Memory: 15.4 GiB of RAM Graphics Processor: Mesa Intel® UHD Graphics 630 Manufacturer: LENOVO Product Name: 10RRS2G200 System Version: ThinkCentre M920q
Jul 27 12:10:27 rohan-homeII kwin_x11[1968]: qt.qpa.xcb: QXcbConnection: XCB error: 3 (BadWindow), sequence: 7178, resource id: 96469004, major code: 20 (>
Jul 27 12:10:27 rohan-homeII kwin_x11[1968]: qt.qpa.xcb: QXcbConnection: XCB error: 3 (BadWindow), sequence: 7246, resource id: 96469004, major code: 15 (>
Jul 27 12:10:27 rohan-homeII kwin_x11[1968]: qt.qpa.xcb: QXcbConnection: XCB error: 3 (BadWindow), sequence: 7323, resource id: 31531604, major code: 18 (>
Jul 27 12:10:27 rohan-homeII kwin_x11[1968]: qt.qpa.xcb: QXcbConnection: XCB error: 3 (BadWindow), sequence: 7697, resource id: 31531617, major code: 18 (>
Jul 27 12:10:28 rohan-homeII kernel: ain_imager[14360]: segfault at 2e0 ip 0000555b9f26022f sp 00007fffd0463d30 error 4 in ain_imager[555b9f14e000+1c2000]>
Jul 27 12:10:28 rohan-homeII kernel: Code: 83 de 0d 00 00 c7 83 78 0d 00 00 ff ff 7f ff 88 83 7c 0d 00 00 48 c7 83 40 b4 0b 00 00 00 00 00 0f 1f 00 48 8b >
Jul 27 12:10:31 rohan-homeII NetworkManager[720]:
Update:
Same problem is seen even after after uninstalling and building the code from scratch. Attached the valgrind trace... ain_imager_segfault.txt
Sorry I do not see the segfault in the valgrind log.
I have compiled both INDIGO 2.0-240 and AIN 1.0-1 according to the instructions, but I see a segfault as soon as I launch AIN. I tried launching AIN in GDB and it seemed to indicate that the segfault was raised in LibRaw release(), though I don't have much experience in GDB. Is there anything I could do to help debug this?
System info: OS: Fedora 37 KDE Spin Kernel: 6.3.8-100.fc37.x86_64 CPU: Intel i7-10875H GPU: Intel UHD Graphics Graphics Platform: Wayland