Ouch! Poop Baby!
Buddy has had a like that from my evil neighbor's dog.
(He gets them on his feet because the dog digs under my fence, then bites Bud)
I just kept them clean and open (so that it can drain) and plenty of antiobotic ointment!

keep us posted and make sure you show these pics to the dog's owner!!!