A patch (for UA) to handle libmagic weirdness on very old platforms