I do feel bad for your friend, given he wasn't meaning any harm, however..
It is an individuals personal responsibility to know the laws in their state and other states they travel through, or visit.
In every state I'm familiar with it's illegal to carry a loaded firearm in your vehicle.
Unless a state has signed reciprocity with the state your permit was issued, your permit is invalid anyway.
The absolute safest thing to do, granted you don't want to know the actual law, is unload your firearm, separate the ammunition to the best of your ability, and secure them both. Hence, leave the ammunition in a box and put your gun in a case or bag.
If you do get stopped, your as safe as you possible could be next to not having it, which I'm not suggesting.
Ignorance doesn't make anything right. Know the laws, protect your self.
H&K Club Member # 120
H&K HK45 / H&K USP Compact .40
Glock 22 Gen 4 (Dept Issue) / Glock 27
Springfield Loaded 1911