I'm not a lawyer... yet. I'm starting my last year of law school in the fall, though.
There is pretty much nothing you can do to avoid getting sued. You can sue anyone for any reason. Now, getting sued and LOSING on the othe hand, is a different thing altogether.
Your best bet is to always operate in the manner that a reasonably prudent person would in the same circumstances and with the same information available to them.
Also, another great defense is being broke. Judgment proof. If you don't have much in the way to take, no attorney is going to take the case on contingency.