The U.S. House of Representatives on Thursday approved a Senate-passed bill to avert a government shutdown next week that also provides the military and some domestic agencies more flexibility in dealing with $85 billion in automatic spending cuts.

The stop-gap measure, which funds government agencies and discretionary programs through the Sept. 30 end of the current fiscal year, won approval in a 318-109 vote, and now moves to President Barack Obama's Desk to be signed into law. New spending legislation was needed by March 27 to avoid a broad government shutdown.