bug fix for division by zero error

Change-Id: I154d61ab9baf6f06fab6934aedf1f38b2cecc7d5