when sending the image from one class to another class application is crashing..


Code..
Qt Code:
  1. if(http_id == id && http->lastResponse().statusCode() == 200)
  2. {
  3. QPixmap image;
  4. QCache<QString,QPixmap>imageCache;
  5.  
  6. QByteArray imagedata = buffer->data();
  7. image.loadFromData(imagedata);
  8.  
  9. imageCache.insert(requestByEntry.key(id),&image);
  10. Form f;
  11. f.set(*imageCache[URL]);
  12. buffer->close();
  13. }
To copy to clipboard, switch view to plain text mode 


Qt Code:
  1. void Form::set( const QPixmap image)
  2. {
  3. m_ui->label->setPixmap(image);
  4. this->show();
  5.  
  6. }
To copy to clipboard, switch view to plain text mode