Honor bypass local gateway setting

This patch make the bypass local gateway setting work.