It is just a technicality. If you know an upper bound on the running time you can simply run it for that many time steps and then return "no" if it doesn't halt by then (because it could never thereon answer "yes"). This only works with concrete upper bounds on running time (and not for general decidability).
That's an odd definition of polynomial time.