Michael Krigsman blogs about "Stopping failure in its tracks":
1. Understand the source of the problem.
2. Decide how to fix it.
Unfortunately sometimes (i.e. often) it's not so easy because "people make projects" (the motto of the IT company I work for).