Pattern
PubSub Client Initialization Hang
pubsub-client-init-hang
Outcome: Now msg will live as long as instance of QtClass lives. | QObject::connect(this, &QtClass::bar, this, &msg. Tension: access violation reading position, msg is out of scope. | introduce a filed of QtClass and capture this — A class member is no option for me. Tension: other answer provided quick fix without thinking about code intent. Outcome: Now msg will live as long as instance of QtClass lives.