It is for reasons similar to this, that I am a Member of Texas Law Shield. After researching all of the "firearms insurance" companies, Texas Law Shield won with flying colors.
Should you be involved in an incident where you are arrested for legally possessing your firearm (pistol or rifle) in a self defense situation or not, they will represent you in court through both the Criminal and Civil Trials.
It is $10 a month, no contract or cancellation fee. A well spent investment in my opinion.