Freaky graphics tearing on Windows

I’m running an SDL 1.2.5 app I wrote under Windows XP (TNT2 graphics adaptor). Whenever I blit to the screen and call SDL_Flip() the machine draws things properly, but sometimes off-center, torn or otherwise wrong.

Is there something I’m doing wrong in my code, or is this just an obscure fault of SDL under Windows? I haven’t noticed this on any other Windows machines…