[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-games-devel
Subject:    Re: [Kde-games-devel] [PATCH] Slight problem with Kshisen
From:       thomas.friedrichsmeier () ruhr-uni-bochum ! de
Date:       2002-07-08 21:42:05
[Download RAW message or body]

> But as far as I see, this should be identical to the existing code... Is this
> some C++ peculiarity, or a compiler bug? I'm using  GCC 2.95.3 on a SuSE 7.2
> system. KDE is compiled from CVS. But the patch works for me! (tm) . 

It seems, before the division was performed on ints and only then converted 
to double, hence you'd easily get 0 as the result. Explicitly casting both 
sides of the / (or actually one side should be enough) to double should 
probably do the trick, too.

Thomas
_______________________________________________
kde-games-devel mailing list
kde-games-devel@mail.kde.org
http://mail.kde.org/mailman/listinfo/kde-games-devel
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic