HP Unified Extensible Firmware Interface Benutzerhandbuch

Seite 72

Advertising
background image

//
// Sample to get list of all environment variables
//
ConstEnvNameList = UefiShellProtocol->GetEnv (NULL);
if (ConstEnvNameList == NULL) {
return EFI_SUCCESS;
}

Print (L"\n");
Print (L"ENVIRONMENT VARIABLES:\n");
Print (L"\n");

//
// Sample to get and display all environment variables
//
while (*ConstEnvNameList != CHAR_NULL){
Value = UefiShellProtocol->GetEnv (ConstEnvNameList);
Print (L"%8s = %s\n", ConstEnvNameList, Value);
ConstEnvNameList += StrLen (ConstEnvNameList)+1;
}
}

return EFI_SUCCESS;
}

72

Das UEFI-Programmiermodell

Advertising
Dieses Handbuch ist für die folgenden Produkte bezogen werden: