After the Battle of Antietam, Ambrose Burnside replaced George McClellan as the new commander of the Union forces. At the Battle of Fredericksburg in December 1862, Burnside's plan to cross the Rappahannock River via pontoon bridges and attack Robert E. Lee was defeated, resulting in heavy Union casualties. In May 1863 at Chancellorsville, Stonewall Jackson led a flanking maneuver through the Wilderness that routed the Union troops, but Jackson was accidentally shot by his own men and died of complications. Despite outnumbering the Confederates, the Union was again defeated at Chancellorsville due to overconfidence and failure to coordinate attacks.