Let's say the Union does better at Second Bull Run becasue the whole Army of the Ptoomac is there to help, but they still can't quite get to Richmond - Lee knocked the Army of the Potomac back in 1864 at North Anna but Grant was determined to keep going, but let's say that the Union instead holds a defensive line inside Virginia a bit north in late 1862, so Lee can't eject them (because he does have a smaller force).
Supposing this butterflies away his invasion of Maryland, and probably Gettysburg, too, does he offer his resignation as he did OTL in August of 1863? Does Davis accept this time? Is he determined to fight a defensive struggle instead? Where would the Union line in Virginia be? I'm thinking the Rappahannock would be good; it would allow them to secure Washington, D.C. a little better since they'd have part of Northern Virginia that borders Washington occupied. Or, maybe a bit further south near Spotsylvania; I'm not sure what the best terrain is there for defense if the Union holds it.