Sam, you beat me to it - I second the Element Fire. I have the E50 in each of my vehicles. However, I would discharge in the aircraft if needed.
Not only is it not corrosive, you can inhale the discharge as it's not toxic, although my personal experience shows you will be coughing - however, it's much better to cough than to burn. And they are easy to use and have almost a minute (50 seconds) of discharge.
If you've ever had a fire right in front of you - 50 seconds is a very long time and more than enough time to get many passes on the base of the fire - or at least aim in the direction you think it's coming from.
I've never used a fire extinguisher in an airplane, but I have used the E50 in a car. It was an electrical fire under the dash of a '68 Mustang. I recommend having one - maybe two. The nice thing about the E50 is that they are compact and easily mounted out the way, but within reach. They have a very long life with, as Sam noted, no stated expiration date.
It's a low cost, easy to use item; much like lighting a road flare. I have two mounted with Elements quick clips in the RV; one in reach of the pilot, and the other under the rear seat brace that either passenger can grab.
I include location and operation of these as part of my pre-flight briefing.