BaseTools/VfrCompile: Add check to avoid using NULL pointer