The bravest wolves willing to wait for a human to throw a scrap of food their way could have mated with other wolves of like temperament. The offspring of this match would have been raised close to humans and would be less fearful than their parents. Over several generations they would be relatively tame.
Soviet scientist Dmitri K. Belyaev demonstrated this in the 1950s with wild silver foxes. He designed a program that mated the ones most curious and least aggressive toward humans. After 40 generations, their offspring were tame, and changed physically. The ears changed, tails became shorter, their color changed and they lost the musky odor associated with earlier generations of wild foxes. After several generations, they became tame enough to play with and responded like a dog. This was a result of selecting the tamest to breed. It’s reasonable to think the same pattern happened to change wolves into dogs during prehistory and eventually into their modern form. The Russians experimented with the aggressive foxes and produced animals that were extremely aggressive. They developed different sounds and mannerisms than the wild silver foxes. Efforts to tame wolves by taking newborn pups have been unsuccessful though. Everything is fine for about two months when the animals become too aggressive and headstrong to keep as pets. They won't mind the presence of a human, and if they want something, they will take it even if it means snapping at the human or biting. In essence, dogs stop developing, and their temperament remains at the lovable pup stage as they mature. It’s quite incredible, as if their personality doesn’t mature over a certain stage. This includes the so called aggressive breeds that can be controlled by humans. They don’t seem to pass the pup boundary into the mature phase as wolves do.