Good question. NASA used to have the answer on its pages, but it disappeared a couple of years ago. Luckily, nothing is truly gone from the Inner Tubes, and so I proudly present their answer, ripped from the Wayback Machine. [Their answer is ripped from an even earlier page, referenced in the text.]
Ask an astrophysicist: What happens to a human body in the vacuum of space?
From the now extinct page http://medlib/jsc.nasa.gov/intro/vacuum.html:
How long can a human live unprotected in space?
If you don't try to hold your breath, exposure to space for half a minute or so is unlikely to produce permanent injury. Holding your breath is likely to damage your lungs, something scuba divers have to watch out for when ascending, and you'll have eardrum trouble if your Eustachian tubes are badly plugged up, but theory predicts -- and animal experiments confirm -- that otherwise, exposure to vacuum causes no immediate injury. You do not explode. Your blood does not boil. You do not freeze. You do not instantly lose consciousness.
Various minor problems (sunburn, possibly "the bends", certainly some [mild, reversible, painless] swelling of skin and underlying tissue) start after ten seconds or so. At some point you lose consciousness from lack of oxygen. Injuries accumulate. After perhaps one or two minutes, you're dying. The limits are not really known.
You do not explode and your blood does not boil because of the containing effect of your skin and circulatory system. You do not instantly freeze because, although the space environment is typically very cold, heat does not transfer away from a body quickly. Loss of consciousness occurs only after the body has depleted the supply of oxygen in the blood. If your skin is exposed to direct sunlight without any protection from its intense ultraviolet radiation, you can get a very bad sunburn.
At NASA's Manned Spacecraft Center (now renamed Johnson Space Center) we had a test subject accidentally exposed to a near vacuum (less than 1 psi) in an incident involving a leaking space suit in a vacuum chamber back in '65. He remained conscious for about 14 seconds, which is about the time it takes for O2 deprived blood to go from the lungs to the brain. The suit probably did not reach a hard vacuum, and we began repressurizing the chamber within 15 seconds. The subject regained consciousness at around 15,000 feet equivalent altitude. The subject later reported that he could feel and hear the air leaking out, and his last conscious memory was of the water on his tongue beginning to boil.
Aviation Week and Space Technology (02/13/95) printed a letter by Leonard Gordon which reported another vacuum-packed anecdote:
"The experiment of exposing an unpressurized hand to near vacuum for a significant time while the pilot went about his business occurred in real life on Aug. 16, 1960. Joe Kittinger, during his ascent to 102,800 ft (19.5 miles) in an open gondola, lost pressurization of his right hand. He decided to continue the mission, and the hand became painful and useless as you would expect. However, once back to lower altitudes following his record-breaking parachute jump, the hand returned to normal."
More info and references are at the link.
So I think Doctor Who got it right, don't you?