fixed potential overflow :)