0
Files
src/content/app_shim_remote_cocoa
Leonard Grey b05b183c27 Mac: fix PWA drag crash
content::GetContentClient()->browser() is null in the app shim, so we
currently crash when trying to fetch a default download file name.

A while ago, we discussed pumping the default name through Mojo, but
my thinking is that this is a lot of complexity for little gain.

This change uses a blank string as the default instead of trying to
fetch one from the browser if the browser is null. Empirically, in an
us/en locale on macOS 10.15.6, we end up with "download.png", which
is (IMO) better than the default "download" anyway. If this ends up
being a problem, we can always pipe through the default later, but
let's fix the crash for now.


Bug: 1019128
Change-Id: I5e941511b3c479841e172a30b72bf69c2c8782f7
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2431546
Commit-Queue: Avi Drissman <avi@chromium.org>
Auto-Submit: Leonard Grey <lgrey@chromium.org>
Reviewed-by: Avi Drissman <avi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#810634}
2020-09-25 15:35:37 +00:00
..
2020-09-25 15:35:37 +00:00