[Bug 35563] New: GetProcessMemoryInfo() is unimplemented

wine-bugs at winehq.org wine-bugs at winehq.org
Mon Feb 10 01:16:36 CST 2014


http://bugs.winehq.org/show_bug.cgi?id=35563

            Bug ID: 35563
           Summary: GetProcessMemoryInfo() is unimplemented
           Product: Wine
           Version: 1.7.12
          Hardware: x86
                OS: Linux
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: ntdll
          Assignee: wine-bugs at winehq.org
          Reporter: achurch+wine at achurch.org
    Classification: Unclassified

Despite bug 13302, GetProcessMemoryInfo() is still effectively unimplemented,
in that it returns zero in all fields instead of actual data.  The missing code
is in the underlying ntdll call, NtQueryInformationProcess(ProcessVmCounters):
(see http://source.winehq.org/source/dlls/ntdll/process.c#L231)

case ProcessVmCounters:
    {
        VM_COUNTERS pvmi;
[...]
        /* FIXME : real data */
        memset(&pvmi, 0 , sizeof(VM_COUNTERS));

Test program (compile with -lpsapi):

#include <assert.h>
#include <windows.h>
#include <psapi.h>
int main(int argc, char **argv) {
    PROCESS_MEMORY_COUNTERS pmc;
    assert(GetProcessMemoryInfo(GetCurrentProcess(), &pmc, sizeof(pmc)));
    assert(pmc.WorkingSetSize > 0);
    return 0;
}

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.



More information about the wine-bugs mailing list