Commit 91e4394c authored by Nikolay Sivov's avatar Nikolay Sivov Committed by Alexandre Julliard

qmgr: Simplify GetProgress() with a structure copy.

parent da5151fd
......@@ -122,9 +122,7 @@ static HRESULT WINAPI BackgroundCopyFile_GetProgress(
TRACE("(%p)->(%p)\n", file, pVal);
EnterCriticalSection(&file->owner->cs);
pVal->BytesTotal = file->fileProgress.BytesTotal;
pVal->BytesTransferred = file->fileProgress.BytesTransferred;
pVal->Completed = file->fileProgress.Completed;
*pVal = file->fileProgress;
LeaveCriticalSection(&file->owner->cs);
return S_OK;
......
......@@ -506,10 +506,7 @@ static HRESULT WINAPI BackgroundCopyJob_GetProgress(
return E_INVALIDARG;
EnterCriticalSection(&This->cs);
pVal->BytesTotal = This->jobProgress.BytesTotal;
pVal->BytesTransferred = This->jobProgress.BytesTransferred;
pVal->FilesTotal = This->jobProgress.FilesTotal;
pVal->FilesTransferred = This->jobProgress.FilesTransferred;
*pVal = This->jobProgress;
LeaveCriticalSection(&This->cs);
return S_OK;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment