Ginge, yes I've had it happen before.
Sounds like the DPF was going through a regeneration cycle to burn off soot deposits in the filter and it hadn't completed the process when you switched the engine off. The fan was running as the regeneration process happens at very high temperatures, which would explain the burning smell you noticed.
When regeneration happens on a longer journey when you're travelling at speed and it completes it's cycle before the end of the journey, you're unlikely to ever notice it. Other than the circumstances you've described, I've only ever noticed mine going through regeneration a couple of times when I've been driving in built up areas at low speeds. The gear change indicator indicates for you to change down, to keep the revs up, and when coming to a stop, the engine idle speed is higher than normal.
If you're doing mainly short journeys, probably an idea to go for a longer, faster run regularly to help keep the DPF clear.