Senate passes gap funding bill to avert shutdown