Remove redundant check for end conditions

The outer for loop terminates when i >=p, so calling clearInterval() after
the outer loop has the same effect as calling it at the beggining of the
next call to drawLine().