White House ‘confident’ of averting shutdown as Trump shows flexibility on wall