I don't see how "officer safety" would allow them to nullify your rights and take your gun and especially grab it out of the car themselves. You would probably have a strong legal case against the officer and the department if this really happened. Even if you are pulled over for an infraction they can't start saying "give me your gun, and that bat, and your pocket knives, and that amazingly sharp pencil, and your lighter, and that pet rock of yours, etc."