Don't think you can protect against lungworm, only treat it. I would guess just keep your dog as fit and healthy as you can and become familiar with the symptoms of the problem.
Zuma had mild case of lungworm 4/5 years ago, I now follow advice of vet who treated him (her own dog had had lungworm) and use Advocate about every 2-3 months - as opposed to the box instruction of every month - as I would prefer that he doesn't even get a mild case again...................worked so far.
7 day dose at the puppy rate of Panacur also treats.
A snail eating former puppy I bred was diagnosed with this (when I told owner to see vet with symptoms of lethargy) before it became more prevalent and she was put on this monthly worming regime.