Fixed bug with floating error

Signed-off-by: Oleg Bulatov <dmage@yandex-team.ru>