Dear visitor, welcome to QtForum.org.
If this is your first visit here, please read the Help. It explains in detail how this page works.
To use all features of this page, you should consider registering.
Please use the registration form, to register here or read more information about the registration process.
If you are already registered, please login here.
QQueue problem
I attempted to use QQueue to pass some information from one thread to many threads. In each of the sub threads, I call dequeue() and have learned that this causes problems since the queues all point to the same set of data. When an object is dequeued from one, it is destroyed and a subsequent dequeue() from another thread results in a seg fault.
Any suggestions for alternative data structures or does I need some redesign?
My application takes data from one thread and sends it across two separate serial points. I was hoping to just pass the queue from the main thread to the serial threads and have them each call dequeue()...
RE: QQueue problem
How many queues do you have? Have you protected them with mutexes?