mortendynamite / g19daemon

Linux daemon for Logitech G19 Keyboard
GNU General Public License v3.0
19 stars 9 forks source link

Segmentation Fault #1

Closed ghost closed 7 years ago

ghost commented 7 years ago

Did not have a problem until the second run. Looks like segfault is caused by uninitialized variables around g19daemon:107.

valgrind output

==10369== Conditional jump or move depends on uninitialised value(s) ==10369== at 0x114E99: g19daemon::~g19daemon() (g19daemon.cpp:107) ==10369== by 0x113E4D: main (main.cpp:33) ==10369== ==10369== Use of uninitialised value of size 8 ==10369== at 0x5E55532: QSettings::setValue(QString const&, QVariant const&) (in /usr/lib/x86_64-linux-gnu/libQt5Core.so.5.6.1) ==10369== by 0x114EDE: g19daemon::~g19daemon() (g19daemon.cpp:108) ==10369== by 0x113E4D: main (main.cpp:33) ==10369== ==10369== Invalid read of size 8 ==10369== at 0x5E55532: QSettings::setValue(QString const&, QVariant const&) (in /usr/lib/x86_64-linux-gnu/libQt5Core.so.5.6.1) ==10369== by 0x114EDE: g19daemon::~g19daemon() (g19daemon.cpp:108) ==10369== by 0x113E4D: main (main.cpp:33) ==10369== Address 0x8 is not stack'd, malloc'd or (recently) free'd ==10369== ==10369== ==10369== Process terminating with default action of signal 11 (SIGSEGV) ==10369== Access not within mapped region at address 0x8 ==10369== at 0x5E55532: QSettings::setValue(QString const&, QVariant const&) (in /usr/lib/x86_64-linux-gnu/libQt5Core.so.5.6.1) ==10369== by 0x114EDE: g19daemon::~g19daemon() (g19daemon.cpp:108) ==10369== by 0x113E4D: main (main.cpp:33)