Fixed access to invalid bitmap bug.

Refactored code a little bit.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@5746 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Michael Pfeiffer
2003-12-24 10:14:28 +00:00
parent 5aa7212658
commit 491eb383e0
3 changed files with 97 additions and 39 deletions
+4
View File
@@ -1945,6 +1945,10 @@ ShowImageView::DoImageOperation(ImageProcessor::operation op, bool quiet)
ImageProcessor imageProcessor(op, fBitmap, msgr, 0);
imageProcessor.Start(false);
BBitmap* bm = imageProcessor.DetachBitmap();
if (bm == NULL) {
// operation failed
return;
}
// update orientation state
if (op != ImageProcessor::kInvert) {