I have a table with model set to QSqlQueryModel, which acquires data from MySQL server.
I connected the doubleClicked signal to a slot so I can open a dialog with data of the selected row, on which I have a reject and accept button.
If I reject, there is no problem, the dialog closes, If I accept on the other hand, the whole app crashes.
Here is another thing that you need to know, for that table I added another shortcut which activates when pressing Return key and this issue does not occur when I open the dialog using the Return key, just when opening with doubleclick.

Here is what I get when using debugger:
Qt Code:
  1. Function: _ZN17QAbstractItemView21mouseDoubleClickEventEP11QMouseEvent
  2. 0x7ffff791bff6 <+0x01f6> or $0xe8ef8948,%eax
  3. 0x7ffff791bffb <+0x01fb> jno 0x7ffff791bf80 <_ZN17QAbstractItemView21mouseDoubleClickEventEP11QMouseEvent+384>
  4. 0x7ffff791bffd <+0x01fd> (bad)
  5. 0x7ffff791bfff <+0x01ff> jmpq 0x7ffff791bf52 <_ZN17QAbstractItemView21mouseDoubleClickEventEP11QMouseEvent+338>
  6. 0x7ffff791c004 <+0x0204> mov (%rbx),%rax
  7. 0x7ffff791c007 <+0x0207> mov %rbp,%rdi
  8. 0x7ffff791c00a <+0x020a> mov 0x2d0(%rax),%r13
  9. 0x7ffff791c011 <+0x0211> callq 0x7ffff76c43c0 <_ZNK21QPersistentModelIndexcvRK11QModelIndexEv@plt>
  10. 0x7ffff791c016 <+0x0216> mov %r12,%rcx
  11. 0x7ffff791c019 <+0x0219> mov $0x2,%edx
  12. 0x7ffff791c01e <+0x021e> mov %rax,%rsi
  13. 0x7ffff791c021 <+0x0221> mov %rbx,%rdi
  14. 0x7ffff791c024 <+0x0224> callq *%r13
  15. 0x7ffff791c027 <+0x0227> test %al,%al
  16. 0x7ffff791c029 <+0x0229> jne 0x7ffff791bff7 <_ZN17QAbstractItemView21mouseDoubleClickEventEP11QMouseEvent+503>
  17. 0x7ffff791c02b <+0x022b> mov %rbx,%rdi
  18. 0x7ffff791c02e <+0x022e> callq 0x7ffff76fe5f0 <_ZNK7QWidget5styleEv>
  19. 0x7ffff791c033 <+0x0233> mov (%rax),%r9
  20. 0x7ffff791c036 <+0x0236> xor %r8d,%r8d
  21. 0x7ffff791c039 <+0x0239> xor %edx,%edx
  22. 0x7ffff791c03b <+0x023b> mov %rbx,%rcx
  23. 0x7ffff791c03e <+0x023e> mov $0x3d,%esi
  24. 0x7ffff791c043 <+0x0243> mov %rax,%rdi
  25. 0x7ffff791c046 <+0x0246> callq *0xf0(%r9)
  26. 0x7ffff791c04d <+0x024d> test %eax,%eax
  27. 0x7ffff791c04f <+0x024f> jne 0x7ffff791bff7 <_ZN17QAbstractItemView21mouseDoubleClickEventEP11QMouseEvent+503>
  28. 0x7ffff791c051 <+0x0251> mov %rbp,%rdi
  29. 0x7ffff791c054 <+0x0254> callq 0x7ffff76c43c0 <_ZNK21QPersistentModelIndexcvRK11QModelIndexEv@plt>
  30. 0x7ffff791c059 <+0x0259> mov %rbx,%rdi
  31. 0x7ffff791c05c <+0x025c> mov %rax,%rsi
  32. 0x7ffff791c05f <+0x025f> callq 0x7ffff791ae30 <_ZN17QAbstractItemView9activatedERK11QModelIndex>
  33. 0x7ffff791c064 <+0x0264> jmp 0x7ffff791bff7 <_ZN17QAbstractItemView21mouseDoubleClickEventEP11QMouseEvent+503>
  34. 0x7ffff791c066 <+0x0000> nopw %cs:0x0(%rax,%rax,1)
To copy to clipboard, switch view to plain text mode