We have been discussing all the issues with legacy code. Now it is time to tackle solving those issues. The first thing we must do is bring sanity to the targeted legacy code, and then we can begin testing and eventually fix the code and bring it back from death.
Dealing with legacy problems
Safe refactoring
The term refactoring is often used incorrectly. When refactoring, you are merely changing the structure of the code. If the logic and/or signature of the code in question changes, then this does not qualify as refactoring. This is a change; most likely a breaking change.
If I'm changing the structure of the code (refactoring), then I don't ever change its behavior at the same time. If I'm changing the interface...