A U.S. passenger flight preparing to leave Washington, D.C., and an incoming military jet received instructions to divert and prevent a possible collision, officials said.