fix spelling and harmonize DEBUG statements in msg.[ch]