I've had a doberman/lab mix come after me. No, I wouldn't go around just tackling dogs, but if it came down to me (or even worse my child) and a dog, that effer would get tackled or whatever it took to ensure our safety. Control the head/neck. It's all canines have to attack with.
Little bro's dog came at me once. As he lunged I swung as hard as I could and knocked him senseless for a bit. Never did it again. His teeth left a small puncture on my knuckle, but I would do it again in a heartbeat.
I love dogs and will NOT harm one unless out of necessity, but eff letting a dog eat your face off bath salt style just b/c it's a pet.
Not that you think this way, but most people are afraid of dogs when honestly a single dog can be handled by most. Not all, I understand, but most grown men, if necessary, could easily handle most dogs bare handed.
Sounds like you did the right thing. Kudos for keeping your cool.