Yeah, that's something of a red herring. The actual ray-sphere intersection happens on line 50:
// sphere_center = (E, F, Z)
E = X - I
F = Y - I
// solving the ray-sphere quadratic eqn...
P = U * E + V * F - W * Z
// discriminant
D = P * P - E * E - F * F - Z * Z + 1
// if solution (ie. intersection) exists
IF D > 0
// intersect_point = ray_orig + T * ray_dir
// this is the closer pt, -P + SQR D is the other
T = -P - SQR D