Ensure that inactivity timer will not be initialize by zero

This was possible in case curtime equals endtime. Also avoids that
the timer was exectly calculated within the range which was the fact