开发者

Why is wszName incorrect?

开发者 https://www.devze.com 2023-03-02 08:23 出处:网络
开发者_JAVA百科WCHAR wszName; In the debugger displays multiple \"squares\" and each addressed 0xcdcd

开发者_JAVA百科WCHAR wszName;

In the debugger displays multiple "squares" and each addressed 0xcdcd

printf("Description: %ws\n", pIfRow->wszName); //prints nothing

Is there a reason it can not get the name from XP?

(All other info in MIB_IFTABLE is correct)

Thanks


0xcdcdcdcd indicates that wszName was never initialized. It is the default value of heap-allocated memory in the Debug build. Review the code that copies a string into wszName, it is not working. Presumably the call to GetIfTable() failed or you're iterating the table wrong.

0

精彩评论

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