It was my fault. I forgot the gate to the garden blows shut in the wind. So all evening when I was leaving him out he was just able to be on the patio.
He whinged at 4am and I left him out but he couldn't go anywhere and ended up pooing on the kitchen floor.
DH, in his groggy half-asleep state, got up to clean it up (I'm 30 weeks pregnant and I think he got confused with cat poo!). It was after he came back to bed we thought of the wind and I got up again and checked and the gate was closed.
I just feel sorry for my poor boy (and I also feel very tired!)