My experience is (and I was bit in the face by our family Great Dane when I was 9) is that dogs give many warning signs before they snap or bite. We actually think our Great Dane snapped at me rather than bit me but obviously because of his size and because I was being VERY annoying and right in his face, his snap caused damage. I truly believe/know it was my fault (and those responsible for me that day) that I got bit. He had been growling at me for ages and giving me many physical signs that I was p*ssing him off, but I just kept persisting, determined to get him to do something. My dad wanted to put him to sleep immediately but I cried and begged for him not to, I loved that dog so much and knew I should have listened to his growling. He didn't get put to sleep and was a fab dog.
My point is is that dogs usually let you know that they are getting to their wits end, it's our job as owners and parents to not let them get to that point. I know your toddler is probably too young to learn the signs but I would persist in being very firm with him about leaving the dog alone, probably to the point of teaching him to not touch the dog at all. I've taught toddlers that I care for to not chase after strange dogs, to stick their hand out to let a dog sniff it before petting, to not chase a pet cat/leave it alone, so I am sure you could get your toddler to that point of knowing that the dog is off limits.
Like I said above, I would probably put a baby-gate up some place where the dog is still comfortable and feels part of the family (I assume he's indoors) but where your toddler can't access him and visa versa where the dog can't access where you toddler predominately plays and hangs out during the day.