PDA

View Full Version : slot sequence to handle http signals



ask8y@yahoo.com
24th June 2010, 17:05
I have two handles to hand these two signals:

connect(myhttp, SIGNAL(requestFinished(int, bool)),
this, SLOT(httpRequestFinished(int, bool)));

connect( myhttp, SIGNAL(responseHeaderReceived(const QHttpResponseHeader &)),
this, SLOT(readResponseHeader(const QHttpResponseHeader &)));

It looks like that the signal generated in this sequence:
1)responseHeaderReceived
2)requestFinished

The slots appeared to be called in sequence:
readResponseHeader (interrupted)
requestFinished(until finish the routine)
readResponseHeader(continue until finished)

The problem I have is that before I can finish handling the problem in readResponseHeader(), and requestFinished() is called with error=true?

Any suggestions?

ask8y@yahoo.com
24th June 2010, 17:23
Hi,

Just found out the abort() is not the normal member but a slot. The behavior I saw is the because I called abort() in the first slot, that triggers the second slot.