SingleApplication
SingleApplication copied to clipboard
chore: Failed to create instance
Sometimes Ubuntu20.04-24.04 execution of d->memory->attach() crashes here and prints the necessary information to determine that the creation has failed
Being able to see that
d->memory->attach(): true
Shared memory creation failed: "QSharedMemory::attach (shm_open): already exists"
Successfully attached to existing shared memory block
Memory block successfully locked
Shared memory data doesn't NULL!
Primary: true "0x1" ← see
Secondary: 0 "0x0" ← see
Primary PID: 9425 "0x24D1"
Checksum: 5070 "0x13CE"
Primary User: vincent
Just skipped the associated judgment and final execution exit ::exit( EXIT_SUCCESS );
Why?
Why do you want all these unnecessary and misleading qCriticals included?
When the creation fails (constructor), nothing logs neither prints. It can be very confusing.
An example process is shown in the video at #201