| 发表于:2007-06-21 14:26:2711楼 得分:5 |
我也没用过这个api,帮你查了一下: const status_info_length_mismatch = (-1073741820) type system_handle_information processid as long objecttypenumber as byte flags as byte handle as integer object as long grantedaccess as long end type type system_handle_information_ex numberofhandles as long handles() as system_handle_information end type declare function zwquerysysteminformation lib "ntdll.dll " (byval infoclass as long, byval buf as long, byval bufsize as long, byval retsize as long) as long declare function zwqueryobject lib "ntdll.dll " (byval objecthandle as long, byval objectinformationclass as long, byval objectinformation as long, byval objectinformationlength as long, byval returnlength as long) as long do mptr = virtualalloc(0, msize, mem_commit, page_readwrite) st = zwquerysysteminformation(system_handle_information, mptr, msize, ret) if st = status_info_length_mismatch then virtualfree mptr, 0, mem_decommit msize = msize * 2 end if loop while st = status_info_length_mismatch | | |
|