I have to say that I didn't find last night's episode nearly as comical as some of the other episodes. I don't know why. I think I laughed once and I don't remember why. I actually kind-of thought the whole cigar in the ear thing was sort-of stupid.
As far as Denny protecting Alan, I think you're on the right track. The writers keep throwing us hints that there may be something deeply wrong with Denny Crane. That's why he acts a little off sometimes. So I believe that Denny knows he's on his way out the door anyway. It's only a matter of time. So why not give Lewiston one more reason to suggest termination? But at the same time, he knows (as well as Lewiston) that he's a darn good lawyer. The firm can't afford to lose him. They can dispose of Alan because he doesn't have the record that Denny has. But they can't lose Denny. So a part of him knows that even if he did something that would've cost the firm millions, Lewiston would never fire him because they need him. So he saved Alan's job by doing what would've gotten him fired but still kept his own job in the process.