ntdll: Return process times in NtQuerySystemInformation(SystemProcessInformation).
Signed-off-by: Zebediah Figura <z.figura12@gmail.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
69e9651c1a
commit
ed566a8723
|
@ -2155,6 +2155,8 @@ NTSTATUS WINAPI NtQuerySystemInformation( SYSTEM_INFORMATION_CLASS class,
|
|||
{
|
||||
int i, j;
|
||||
|
||||
get_thread_times(unix_pid, -1, &spi->KernelTime, &spi->UserTime);
|
||||
|
||||
/* set thread info */
|
||||
i = j = 0;
|
||||
while (ret == STATUS_SUCCESS)
|
||||
|
|
|
@ -833,6 +833,9 @@ BOOL get_thread_times(int unix_pid, int unix_tid, LARGE_INTEGER *kernel_time, LA
|
|||
FILE *f;
|
||||
int i;
|
||||
|
||||
if (unix_tid == -1)
|
||||
sprintf( buf, "/proc/%u/stat", unix_pid );
|
||||
else
|
||||
sprintf( buf, "/proc/%u/task/%u/stat", unix_pid, unix_tid );
|
||||
if (!(f = fopen( buf, "r" )))
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue