Whistler was in command of a brigade in the Defenses of Washington, D.C. from July, 1864 to September 19, 1865, being engaged in the defense of the Capital during the Battle of Fort Stevens, July 11–12, 1864, against the Army of the Valley, principally the detached Second Corps, Army of Northern Virginia, under the command of (temporary) Lieutenant General Jubal Early. Whistler was severely wounded at the Siege of Petersburg He was promoted to major of the 13th U.S. Infantry Regiment on December 31, 1864. Whistler received an appointment as brevet colonel to rank from March 13, 1865, for "Gallant and Meritorious Services during the Rebellion."