MR2v1 - kernelbase: Add support for progress callback in CopyFileEx.

Nikolay Sivov (@nsivov) wine at gitlab.winehq.org
Tue Apr 26 00:40:15 CDT 2022


Nikolay Sivov (@nsivov) commented about dlls/kernelbase/file.c:
> +        return TRUE;
> +
> +    cbret = (*callback)( size, transferred, size, transferred, 1, cbtype, src, dest, param );
> +    if (cbret == PROGRESS_QUIET)
> +    {
> +        *callback = NULL;
> +        return TRUE;
> +    }
> +    else if (cbret == PROGRESS_CANCEL)
> +    {
> +        FILE_DISPOSITION_INFORMATION fdi;
> +        IO_STATUS_BLOCK io;
> +
> +        fdi.DoDeleteFile = TRUE;
> +        NtSetInformationFile(dest, &io, &fdi, sizeof(fdi), FileDispositionInformation);
> +    }
>From what I can tell this does not work. You'll need delete access on dest handle, which according to the test you can't have. Please make sure you don't need to undo last DeleteFile() test.

-- 
https://gitlab.winehq.org/wine/wine/-/merge_requests/2#note_405



More information about the wine-devel mailing list