[Bug Report] SIGSEGV Crash (Race Condition) on Latest Git Build (git1697) during libusb HID Detection
Description of Bug
The application crashes immediately after printing 'Detecting libusb HID devices,' but does not crash when running under gdb or strace. It does crash when run with a command-line argument that forces immediate action, such as --profile [name], suggesting a race condition between device detection and profile application.
Tested by disabling detection (completely, using command-line switch), and OpenRGB runs fine. Tried selectively disabling either all HW, or just those three devices I do use, no impact. Tried wiping out configuration directory, no efect either.
Attached Log
Operating System
"Kubuntu 25.04 - Linux" OpenRGB Version: Latest Git (git1697) libusb Version(s): libusb-0.1-4:amd64 (2:0.1.12-35build1) libusb-1.0-0:amd64 (2:1.0.27-2)[OpenRGB_20251104_155914.log] OpenRazer Version: Latest Git (551c12d1f32cf0c7afdbf0e425683bdfb45cf261)
Hardware Configuration
0: Razer Cobra Pro Type: Mouse Description: Razer Device, Black Version: HID: /dev/hidraw1 Location: HID: /dev/hidraw1 Serial: PM2348H27300436
Modes: [Direct] Off Static Breathing 'Spectrum Cycle' Wave Zones: Logo 'Scroll Wheel' Underglow LEDs: Logo 'Scroll Wheel' 'Underglow LED 1' 'Underglow LED 2' 'Underglow LED 3' 'Underglow LED 4' 'Underglow LED 5' 'Underglow LED 6' 'Underglow LED 7' 'Underglow LED 8' 'Underglow LED 9'
1: X570 AORUS ELITE Type: Motherboard Description: IT8297BX-GBX570 Version: HID: /dev/hidraw0 Location: HID: /dev/hidraw0 Serial: 0x82970100 Modes: [Direct] Static Breathing Flashing 'Color Cycle' 'Double Flash' Wave Random 'Wave 1' 'Wave 2' 'Wave 3' 'Wave 4' Zones: '12V RGB Strips' 'D_LED1 Bottom' 'D_LED2 Top' Motherboard LEDs: 'CPU Header' LED_C1/C2 'Back I/O' PCIe
2: Razer Kraken V4 (Wireless) Type: Headset Description: Razer Device Version: HID: /dev/hidraw8 Location: HID: /dev/hidraw8 Serial: HN2430D33508306 Modes: [Direct] Wave Zones: Headset LEDs: 'Headset LED 1' 'Headset LED 2' 'Headset LED 3' 'Headset LED 4' 'Headset LED 5' 'Headset LED 6' 'Headset LED 7' 'Headset LED 8' 'Headset LED 9'
Tried to use older version (published test release, prior to recent git commit), no avail. Newest version which works with no issue is 0.8, either custom-build, or from distribution repositories. Also tried switching on hid_safe_mode, but apart from slowing down detection, the app still crashes when it gets to HID detection part.