There's a bunch of different approaches you can take to this issue.
Take away their problem
Of course, it'll be hard to prevent out-of-stock entirely. And getting the stock back up asap also speaks for itself.
However, what you could do, is to allow them an other way to interact with the page and let you know that they want this item stocked. One way I've done it in the past, for a company that hosts workshops, is to have a "register interest" button. You could do something similar with a "please restock" button, which you could even link to a form where they can enter their email address so you can follow up when it is back in stock. (See? Two people are winners here)
Advise on due-dates
Frustration can also be taken away by handing the user a due-date (or rough estimate of one). Again, obviously, make sure you get this date right, or at least close, or it could do the opposite and lead to even more frustration.
Explain the situation
Explain why it's out of stock. Ordered too few because unexpected success of a marketing campaign? Let them know this item was out of stock due to "overwhelming success" and tell users to "check back soon!". This creates a need for an item, while also saying "we ordered a ton, but sold a ton and a half!", which actually is a positive thing. It means the item is great, and the crowd loves it. You'll be surprised how far just a reason can go in making people treat you differently.
Review disabled for non-buyers
If your site has a log-in functionality, you could look into allowing only people who actually purchased and received an item to submit comments/reviews.
This is probably the safest way, but might lose you some organically created content because you're obviously limiting sources.
Disable commenting for out of stock items
(I don't recommend this one, but added it for the sake of completion, and because it might help in extreme cases or for specific audiences)
Speaks for itself, but will be controversial because it will affect even people who did order the item. It's a simple option to implement though.
Along the same vein, you can "sink" comments that contain words like "out of stock" or "unavailable" so they don't come up at the top of the comment section. Only really relevant if there are enough results, and might again piss off some users.