Skip to content

Commit 6d96c26

Browse files
authored
Merge pull request #4062 from grandixximo/fix/qtvcp-shutdown-segv
qtvcp: stop QPin update timer before hal_exit to prevent shutdown SIGSEGV
2 parents daf366a + 9cf118c commit 6d96c26

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

src/emc/usr_intf/qtvcp/qtvcp.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -523,6 +523,11 @@ def shutdown(self,signum=None,stack_frame=None):
523523
LOG.debug('Exiting HAL')
524524
if not HAL is None:
525525
try:
526+
# Stop the QPin polling timer before hal_exit; otherwise its
527+
# next tick dereferences pin->u after hal_exit has unmapped
528+
# HAL shmem, causing SIGSEGV on glibc 2.39 (Ubuntu 24.04).
529+
from qtvcp.qt_halobjects import QPin
530+
QPin.update_stop()
526531
HAL.exit()
527532
except Exception as e:
528533
print(e)

0 commit comments

Comments
 (0)