Just a few months ago, the bigwigs at

Samsung Electronics

boasted that flash memory would wipe out the hard-drive industry in the next few years. Now there are persistent rumors that the Korean giant may buy

Western Digital

(WDC) - Get Report

, the world's No. 2 maker of hard drives -- and the chatter is giving Western's shares a bit of a lift.

So, what's a storage investor to do? In two words: Take care. Shares of Western Digital have not done well this year, appreciating by just 4% before Monday's mini-rally, while industry-leading

Seagate

(STX) - Get Report

has soared by 32%.

In recent trading on Monday, shares of Western Digital were up 54 cents, or 2.8%, to $19.97, giving the company more than a 6% run-up over the past four sessions.

Buy-side and hedge fund investors with a stake in Western Digital obviously have something to gain by whispering M&A in the right ears -- and so do investors in Seagate. One manager (who spoke on the condition of anonymity) with a position in Seagate put it this way: "If Samsung buys Western, look for Seagate to hit $35." Seagate's shares closed Friday at $26.33.

Why would Samsung buy Western? "The issue for the industry isn't demand -- it's supply. Removing a competitor means less price-cutting and better margins. I'm rooting for it," the manager said.

Samsung Electronics is a key component of Samsung, the Korean-owned industrial conglomerate, or

chaibol

. The electronics company contains Samsung's very large semiconductor business, which makes flash memory, which has begun to compete with hard drives in consumer devices such as Apple's

(AAPL) - Get Report

iPod.

Despite some headway in consumer devices, which don't need enormous amounts of storage, most analysts believe that flash is unlikely to become cheap enough to displace hard drives in notebook and desktop computers.

In its most recent fiscal year, Western posted a profit of 91 cents a share on sales of $3.6 billion, while Seagate earned $1.41 a share on sales of $7.5 billion.

On the face of it, the deal makes a certain amount of sense. Western Digital has well-established positions selling drives to major PC makers, and Samsung doesn't, says James Porter, founder and principal analyst of DiskTrend, a research boutique specializing in storage.

What's more, Western is an efficiently run company with a reputation for excellent product development. And with the industry moving to a new, denser technology known as "perpendicular" storage, Samsung will need help getting the new products out the door, says Porter.

Overall, though, Porter is skeptical, saying, "Western has good management, is keeping up with the industry and is profitable. I don't see them wanting to sell."

Susquehanna Financial analyst Kaushik Roy rates the acquisition as "unlikely" but does acknowledge that the deal would have certain attractions for Samsung. "The consumer segment of the hard-disk market is growing at 30% a year," he said. But unlike Western Digital, Samsung has no presence there," he said. Roy, too, is not convinced that Western's management wants to sell.