If you ever have a situation where your dog does growl at you the very last thing you do is smack, shout or punish in any way at all - your dog is not happy and is warning you to back off - any further action from you could well end up in a bite being forthcoming.
Dog's exhibit what are called Calming / Appeasement Signals and there is a good chance that the dog showed several of these before the growl occurred. There could have been behaviour such as the dog turning it's head or body away from you - perhaps even licking its lips at the same time and/or blinking.
t's body may have become a bit more submissive with tail going lower and possibly even body going lower. You may have noticed that it's eyes went a bit harder than usual, or the top of the muzzle went tight with the whiskers becoming a bit more prominent.
If you stood over you dog it may have just walked away, or if you approached from behind the dog and it was stuck into a lovely bone for example, the dog may turn sharply and stare at you. Here there could be further signs being shown as well such as hardening of the eyes, a bit of staring etc.
Any of these above would signal that a dog is not happy. Behaviour never 'just happens', there is, 99.9% of the time signs that are leading up to the growl. If the dog is punished for growling, the next time, the dog may still exhibit the signs that not happy, however as the Growl did not work the last time, plus the dog was punished for it, the Growl may not occur and a bite does instead!
A common area where growls occur is when a dog has possession of an object and does not want to give it back - don't fight this, as below get in an expert who will teach you how to get your dog to Swap or Leave any object in it's mouth. Dog's are natural resource guarders and it is very simple to teach your dog to relinquish objects in its mouth without growling.
All of the above are signs that the dog wants you to back off and unfortunately we as humans do not always recognize them. Is it acceptable for our dogs to growl at us - no, however punishment will not stop the behaviour. What you need to do is to consult an animal behaviour consultant for help. They will explain to you why the behaviour is happening and show you the signs that your dog is exhibiting before the growling starts. They will tell you why the behaviour is occurring and most importantly they will give you the tools you need to prevent this from happening, or if it does happen, how to deal with it.
To get hold of a canine behaviour consultant www.animal-behaviour.org.za
Here is a link to some posters on Body Language to increase your knowledge on dogs:-