I think it's going to be extremely hard to pinpoint that exact episode on such a small scene so long after any Benny Hill has been shown here, you may get better luck on the Benny Hill Fan Club website. I know I have seen this, I can picture it clearly but it doesn't help with identify the episode.
But I'd have a guess it was from his late period made in USA shows, late 80s to 1990ish and were pretty decent shows considering his age but not as good as his early 70s golden period.
He took to doing more little narrative spoofs of films or shows or American tropes or characters for his US shows and I have a strongish feeling I saw this or a very similar prison escape vignette in that period. I avidly watched all his 'comeback' shows as he was by then a huge star in the US and his new material tailored for the American market went down a storm I recall, they were very flattered by his efforts to 'Americanise' it.
So I'd look there first, his made in America shows (I think still Thames/ITV produced). Not too many shows to choose from. Apologies if it's from much earlier but it could even be from both as Benny did recycle a few of his sketches or put different slants on the same gags.