The seven-year-old pet's heart arteries hardened after being afflicted with the parasites.
However, vet Ben Harris found its saviour in the anti-impotence pills Viagra, which finally restored Bentley's blood flow to normal.
The dog, owned by David Roach, was taken to Ben after it grew increasingly breathless.
After conducting scans, it was found that Bentley was infected with potentially lethal lungworms, which had spread to its pulmonary artery, which carries blood from the heart to the lungs.
"When Bentley came to us he was barely able to walk a few steps," The Sun quoted Ben as saying.
Saxophonist David, of East Finchley, North London, said: "Now he's happy and active again, we're delighted."