Correct a couple of minor bugs that broke messages with multiple intermediate headers.