Marathon debug session last night. Finally found it, which turned out to be a problem that had been in the code for years, but lay undiscovered until I walked into it. Today I am exhausted but happy. And a little brain-dead.