[webkit-changes] [WebKit/WebKit] f109be: Progress reporting is not started for blob downloads

Per Arne Vollan noreply at github.com
Fri Nov 1 10:46:46 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: f109be54bd9d43976c8667cc9591da2c0410eb28
      https://github.com/WebKit/WebKit/commit/f109be54bd9d43976c8667cc9591da2c0410eb28
  Author: Per Arne Vollan <pvollan at apple.com>
  Date:   2024-11-01 (Fri, 01 Nov 2024)

  Changed paths:
    M Source/WebKit/NetworkProcess/Downloads/Download.cpp
    M Source/WebKit/NetworkProcess/Downloads/Download.h
    M Source/WebKit/NetworkProcess/Downloads/cocoa/DownloadCocoa.mm
    M Source/WebKit/NetworkProcess/NetworkProcess.cpp

  Log Message:
  -----------
  Progress reporting is not started for blob downloads
https://bugs.webkit.org/show_bug.cgi?id=282393
rdar://138012063

Reviewed by Chris Dumez.

The reason for this is that we were starting the reporting after an early return in NetworkProcess::findPendingDownloadLocation,
when the download already had completed. This patch addresses this by moving the start of the reporting to before that point.
Additionally, there was an issue for blob downloads where we would update the progress of the download before the system had
started observing the progress object we were updating. This has been addressed by only starting progress updates after
Download::startUpdatingProgress was called, which was already the case for non-blob downloads.

* Source/WebKit/NetworkProcess/Downloads/Download.cpp:
(WebKit::Download::didReceiveData):
* Source/WebKit/NetworkProcess/Downloads/Download.h:
* Source/WebKit/NetworkProcess/Downloads/cocoa/DownloadCocoa.mm:
(WebKit::Download::publishProgress):
(WebKit::Download::startUpdatingProgress):
(WebKit::Download::updateProgress):
(WebKit::Download::startUpdatingProgress const): Deleted.
* Source/WebKit/NetworkProcess/NetworkProcess.cpp:
(WebKit::NetworkProcess::findPendingDownloadLocation):

Canonical link: https://commits.webkit.org/286012@main



To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications


More information about the webkit-changes mailing list