In Ch.54 Abel Magwitch alias Provis is caught and arrested by the London Police. At the end of the chapter Pip informs us that Magwitch will have to face trial and that it is certain that he will be hanged and all his property and wealth will be confiscated by the Government,
"that there were, still living, people enough who were able and willing to identify him, I could not doubt. That he would be leniently treated, I could not hope. He who had been presented in the worst light at his trial, who had since broken prison and had been tried again, who had returned from transportation under a life sentence, and who had occasioned the death of the man who was the cause of his arrest."
Just before he is arrested Magwitch is seriously injured when he fights with Compeyson his life long enemy. In Ch. 56 Magwitch is sentenced to death and he accepts the sentence with equanimity saying,
"My Lord, I have received my sentence of Death from the Almighty, but I bow to yours."
In Ch. 54 when Magwitch was badly injured when he was arrested, Pip hopes that Magwitch dies soon so that he is not hanged at the gallows like an ordinary criminal "since it was unquestionably best that he should die."
At the end of Ch.56 Pip's wish is fulfilled when Magwitch dies after kissing Pip's hand,
"with a last faint effort, which would have been powerless but for my yielding to it and assisting it, he raised my hand to his lips. Then, he gently let it sink upon his breast again, with his own hands lying on it. The placid look at the white ceiling came back, and passed away, and his head dropped quietly on his breast."