diff --git a/src/apps/deskbar/BarMenuTitle.cpp b/src/apps/deskbar/BarMenuTitle.cpp index 6651e4b5fa..90e5150105 100644 --- a/src/apps/deskbar/BarMenuTitle.cpp +++ b/src/apps/deskbar/BarMenuTitle.cpp @@ -137,12 +137,14 @@ TBarMenuTitle::DrawContent() menu->SetDrawingMode(B_OP_ALPHA); - BRect dstRect(fIcon->Bounds()); - dstRect.OffsetTo(frame.LeftTop()); - dstRect.OffsetBy(rintf(((frame.Width() - dstRect.Width()) / 2) - 1.0f), - rintf(((frame.Height() - dstRect.Height()) / 2) - 0.0f)); + if (fIcon != NULL) { + BRect dstRect(fIcon->Bounds()); + dstRect.OffsetTo(frame.LeftTop()); + dstRect.OffsetBy(rintf(((frame.Width() - dstRect.Width()) / 2) - 1.0f), + rintf(((frame.Height() - dstRect.Height()) / 2) - 0.0f)); - menu->DrawBitmapAsync(fIcon, dstRect); + menu->DrawBitmapAsync(fIcon, dstRect); + } }