diff --git a/OvmfPkg/VirtioFsDxe/DriverBinding.c b/OvmfPkg/VirtioFsDxe/DriverBinding.c index 86eb9cf0ba..69d2bb7770 100644 --- a/OvmfPkg/VirtioFsDxe/DriverBinding.c +++ b/OvmfPkg/VirtioFsDxe/DriverBinding.c @@ -218,6 +218,10 @@ VirtioFsGetDriverName ( OUT CHAR16 **DriverName ) { + if ((Language == NULL) || (DriverName == NULL)) { + return EFI_INVALID_PARAMETER; + } + if (AsciiStrCmp (Language, "en") != 0) { return EFI_UNSUPPORTED; }