fix the code so not to invoke callback twice
simply the code
Merge pull request #1373 from yugangw-msft/vmlistfailure

fix the code so not to invoke callback twice