Hands down, I think the 17HMR far out performs the 22 mag in every situation, accuracy,velocity, killing power and flatness of trajectory. For fox, I don't think you can loose going with the HMR. Ive killed a couple dozen coyotes with the 17HMR, and most of them were killed quite neatly, but it is obviously light for the job.
The maggie just doesn't have enough steam to reliably do what the 17HMR will do consistently. A 22 mag, will many times just "pencil" thru an animals vitals without disrupting them like the HMR will do. The 17HMR acts more like a conventional rifle cartridge, small yes, but still has the velocity to cause some major hydrostatic damage.