我正在尝试写一个简单的驱动程序。 使用这个Hello World代码:
#include <ntddk.h> NTSTATUS DriverEntry(IN PDRIVER_OBJECT DriverObject, IN PUNICODE_STRING RegistryPath) { UNREFERENCED_PARAMETER(DriverObject); UNREFERENCED_PARAMETER(RegistryPath); DbgPrint("Hello World\n"); return STATUS_SUCCESS; }
但是我得到这个错误:
Error 1 error -2: "Inf2Cat, signability test failed." Double click to see the tool output.
我不确定这是什么意思。 我使用Win7 Debugconfiguration设置。
我做了类似的程序,它对win7的调试配置完美的工作
#include "ntddk.h" #include "stdio.h" #include "stdlib.h" void DriverUnload( PDRIVER_OBJECT pDriverObject) { DbgPrint("Driver unloading\n"); } NTSTATUS DriverEntry( PDRIVER_OBJECT DriverObject, PUNICODE_STRING RegistryPath) { PDEVICE_OBJECT pdo; DriverObject->DriverUnload = DriverUnload; DbgPrint("Hello, World\n"); return STATUS_SUCCESS; }
也可以检查任何64位装饰错误的猫文件
解决方案是project-> propeties-> ConfigurationProperties-> inf2Cat-> General-> UseLocalTime->是