• Joe Laughlin's avatar
    Fix leak of process_token. · 7d7efd9f
    Joe Laughlin authored
    The calls to GetCurrentProcessToken() return a process token handle
    that must be closed. This function is implemented in the same file,
    and calls OpenProcessToken(). Win8 and later OSes have a function
    of the same name ::GetCurrentProcessToken() which returns a
    psuedo-handle that does not need to be closed.
    
    The # Enter a description of the change.
    Fix handle leaks of the process_token.
    
    Bug: 1126279
    Change-Id: Idbeaa92a173409a7b7152c04dcc67c917e8c306e
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2402081
    Commit-Queue: Joe Laughlin <joel@microsoft.com>
    Commit-Queue: Nico Weber <thakis@chromium.org>
    Reviewed-by: default avatarBruce Dawson <brucedawson@chromium.org>
    Reviewed-by: default avatarNico Weber <thakis@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#810385}
    7d7efd9f
process_info_win.cc 2.75 KB