Law enforcement officials say Vester Flanagan used a Glock handgun in Wednesday's shooting, one of two that he bought last month.

The officials say he legally bought two Glock model 19 handguns, one of the world's most widely sold firearms, from a Virginia dealer that they declined to identify.

Though Flanagan said in his letter to ABC News that he "put down a deposit for a gun" on June 19, the background check requirement would not kick in until he actually sought to take possession of the gun, which was in July. Putting money down on firearms is common, especially in the South, says a federal law enforcement official.

Nothing in Flanagan's background disqualified him from buying a gun. He was arrested in Greenville, North Carolina, in 2004. But that case was for a traffic offense that, according to court records, was later dismissed. It was a misdemeanor charge: Even if he had been convicted, it would not have made him ineligible.

As for his mental health, the standard in federal law is very high: "adjudicated as a mental defective" or "committed to a mental institution." Nothing in Flanagan's history indicates that either standard fit him, despite his reputation as an unstable co-worker.