What do you do when your company's stock price plummets by more than 40 percent in a single day? Most of us hope never to have to find out, but if we do, I can't think of a better example of how to handle it than Jeff Weiner has given us over the past few weeks. 

The trouble began when LinkedIn executives realized that the company's revenue growth was slowing. In a high-tech world where the rule is not only grow-or-die, but grow-at-a-relentlessly-increasing-pace-or-die, that was bad news. CEO Jeff Weiner's response to that bad news has been nothing short of brilliant, and a great lesson for anyone running a business.

Here's what he did right:

1. Announce the bad news before anyone else does.

LinkedIn's trouble began on February 4, when it announced its earnings for the most recent quarter. Those numbers were fine, but company executives could see revenue growth slowing. So, as every public company does, they offered "guidance"--their prediction of how earnings would perform in the next three months. That guidance was lower than stock analysts had expected. Because LinkedIn's stock price was very high compared to how much money it makes, the market reacted with consternation, expressed in a rapid sell-off that caused LinkedIn's stock to plummet by 44 percent at one point the following day.

That was a bad reaction, likely brought on in large part by general uncertainty around the stock market right now. But it could have been much, much worse if the company had offered guidance closer to what the market expected, and then missed that guidance by a wide margin a few months from now.

2. Keep talking.

Weiner's first reaction to the stock plunge was an all-hands meeting of LinkedIn employees where he put the price drop in its proper context. First, he told employees that all companies face issues like this one--the question is how they navigate those moments. And then he reminded them, as CEOs will at such moments, that LinkedIn was exactly the same company it had been the day before it announced its guidance.

3. Focus on the big picture.

Then he started talking about the macro forces at work in the world and how LinkedIn fits into them. One part of the bigger picture is that LinkedIn is a business-focused social network and therefore likely to be affected by the general business outlook. Indeed, the company said some of its weakness comes from the downturn in Europe which slowed sales of its recruitment software. Business goes in cycles so what weakened it today will likely strengthen it tomorrow. (The same can't be said for competition from Facebook's new professional-focused product which is also making investors nervous. It will be interesting to see whether that steals away some of LinkedIn's business or not.)

4. Show how much you care.

Weiner's next act was striking--he decided to put the $14 million stock grant he would have received this year back into the pool for LinkedIn employees, many of whom own LinkedIn stock or stock options and thus saw their own net worth plunge as well. No word yet on how this will be distributed, but it's a great grand gesture, and a show of commitment to the company. Weiner isn't the first to do something like this--that distinction belongs to Jack Dorsey who gave $200 million in stock and stock options to Twitter employees after that company went through layoffs and a stock price drop of its own. And, as many observers have noted, Weiner already has LinkedIn stock worth almost $13 million, and stock options that if exercised today would be worth more than $55 million. So, yes, he can certainly afford to be generous.

Nevertheless it's a fantastic move for a couple of reasons. First: In a tight market for tech talent, he's given employees a good reason to stay at the company and demonstrated his own commitment to it and them. And second, he's "captured the news cycle" as they say. Instead of focusing on LinkedIn's problems, the press is focused on his big giveaway, at least for now.