This is explained in "Time Crash", the 2007 Children in Need special, which takes place immediately before "Voyage of the Damned". The plot of the special revolves around the TARDIS from Tennant's era merging with the TARDIS from Peter Davison's (the Fifth Doctor's) era; Tennant explains how this is possible (emphasis mine):
Doctor 5: In a minute we're going to create a black hole strong enough to swallow the entire universe!
Doctor: Yeah, that's my fault, actually. I was rebuilding the Tardis, forgot to put the shields back up.
Doctor Who "Time Crash"
At the end of the special, Davison gets a last jab at Tennant, and reminds him that he still hasn't put the shields up:
Doctor 5 [OC]: Oh, Doctor, remember to put your shields up.
(But just as he presses the button, there is the sound of a ships horn and a prow comes crashing into the console room.)
Doctor Who "Time Crash"
Which is where "Voyage of the Damned" picks up.
It's also hinted at in the episode itself, but it's a pretty throwaway line so it's easy to miss:
Astrid: How'd you get on board?
Doctor: Accident. I've got this, sort of, ship thing. I was just rebuilding her. Left the defences down. Bumped into the Titanic. Here I am. Bit of a party. I thought, why not?
Doctor Who "Voyage of the Damned"