In the very beginning of Game of Thrones, we see a Night's Watch soldier, Gared, deserting his brother after seeing the White Walkers and Wights. He is later captured by Stark soldiers and brought before Ned Stark, the Lord of Winterfell. Ned Stark executes him in the name of King Robert.
The crime for deserting the Night's Watch is execution as stated later by Samwell to Jon Snow. But why did a Lord of Winterfell execute a deserter of the Night's Watch. Why didn't Ned hand him over to Lord Commander Mormont?
In season 2, when Theon is holding Winterfell and Bolton men are at the gates, Maester Luwin tells Theon to run to the north and join the Night's Watch. He says that, once he joins the Night's Watch he will be out of reach of any Lord or King of Westeros.
So, Ned being honorable and all should have sent Jared back to the Wall for Commander Mormont to decide what to do with him no? Mormont even tells Jon that even though they take all kinds of oaths, he still forgives brothers who go to Mole's town brothels.
He says that, once he joins the Night's Watch he will be out of reach of any Lord or King of Westeros.
Aye he'd be out of their reach as in they wouldn't be able to punish him for any crimes or allegiances he had before taking the black. As long as he remains true, he'll be safe. If he deserts and is caught on any Lord's lands, that lord has the legal right to execute him and keep the King's peace.