From 181ecd0c3bf27b47487f973fb83b988fd6ceaecf Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sat, 2 Mar 2013 21:17:13 +0300 Subject: Another fixes after Coverity checks. --- src/gui/statuswindow.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'src/gui/statuswindow.cpp') diff --git a/src/gui/statuswindow.cpp b/src/gui/statuswindow.cpp index 99ee0e655..ddd16fa12 100644 --- a/src/gui/statuswindow.cpp +++ b/src/gui/statuswindow.cpp @@ -177,10 +177,8 @@ StatusWindow::StatusWindow() : if (!max) max = 1; - mHpBar = new ProgressBar(this, max ? - static_cast(PlayerInfo::getAttribute(PlayerInfo::HP)) - / static_cast(max): - static_cast(0), 80, 0, Theme::PROG_HP); + mHpBar = new ProgressBar(this, static_cast(PlayerInfo::getAttribute( + PlayerInfo::HP)) / static_cast(max), 80, 0, Theme::PROG_HP); max = PlayerInfo::getAttribute(PlayerInfo::EXP_NEEDED); mXpBar = new ProgressBar(this, max ? -- cgit v1.2.3-70-g09d2