开发者

Detect KITL at runtime

开发者 https://www.devze.com 2022-12-30 01:38 出处:网络
In Windows CE it is a trivial thing to conditionally compile something if KITL is enabled: #if IMGNOKITL == 1

In Windows CE it is a trivial thing to conditionally compile something if KITL is enabled:

#if IMGNOKITL == 1
DoSomething();
#else
DoSomethingElse();
#endif

But I need to produce开发者_开发技巧 a user mode application that detects at runtime if KITL is enabled or not. It is possible?


I tried to look for such a function in Windows CE 6 and could not find anything. Why don't you add your own global variable to the OAL:

#ifdef IMGNOKITL
DWORD g_dwKitlEn = 1;
#else 
DWORD g_dwKitlEn = 0
#endif

And then add a kernel IOCTL that returns the value of that variable. That way when you move between Windows CE versions the method will still work for sure (as long as the IMGNOKITL variable does not change).

0

精彩评论

暂无评论...
验证码 换一张
取 消