diff --git a/src/plugins/intel_npu/src/compiler_adapter/include/compiler_adapter_factory.hpp b/src/plugins/intel_npu/src/compiler_adapter/include/compiler_adapter_factory.hpp index ff6dc6246a121d..a23ba2b5990299 100644 --- a/src/plugins/intel_npu/src/compiler_adapter/include/compiler_adapter_factory.hpp +++ b/src/plugins/intel_npu/src/compiler_adapter/include/compiler_adapter_factory.hpp @@ -19,14 +19,13 @@ class CompilerAdapterFactory final { auto compilerType = config.get(); switch (compilerType) { case ov::intel_npu::CompilerType::MLIR: { - if (engineBackend->getName() != "LEVEL0") { + if (engineBackend == nullptr || engineBackend->getName() != "LEVEL0") { return std::make_unique(nullptr); } - return std::make_unique(engineBackend->getInitStructs()); } case ov::intel_npu::CompilerType::DRIVER: { - if (engineBackend->getName() != "LEVEL0") { + if (engineBackend == nullptr || engineBackend->getName() != "LEVEL0") { OPENVINO_THROW("NPU Compiler Adapter must be used with LEVEL0 backend"); }