New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 829099 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: Jun 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 2
Type: Bug



Sign in to add a comment

Sharing a page would cause a crash

Project Member Reported by romax@chromium.org, Apr 4 2018

Issue description

Steps:
1. make sure sharing flag is off.
2. download a page, it will be in private dir.
3. turn on the sharing flag.
4. load the downloaded page in 2 from Download Home
5. Use clank overflow menu to share the item, to any client.
6. come back to Chrome and share again

it will crash here.
 
Project Member

Comment 1 by bugdroid1@chromium.org, Apr 6 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/c6890df307bc3782afbc63d651a83abf4b6f8607

commit c6890df307bc3782afbc63d651a83abf4b6f8607
Author: Pete Williamson <petewil@chromium.org>
Date: Fri Apr 06 17:42:20 2018

Fix crash when sharing page twice.

We were referencing a null pointer to try and get values.  Changed to
use default null values.

This fixes the symptom (the crash), but not the underlying cause. The
underlying cause is more complex and will be fixed in another patch.

Bug:  829099 
Change-Id: Ida10bd9366afac8dbbcbb5c2b7d41d36b0d46759
Reviewed-on: https://chromium-review.googlesource.com/996796
Reviewed-by: Yafei Duan <romax@chromium.org>
Commit-Queue: Peter Williamson <petewil@chromium.org>
Cr-Commit-Position: refs/heads/master@{#548847}
[modify] https://crrev.com/c6890df307bc3782afbc63d651a83abf4b6f8607/chrome/android/java/src/org/chromium/chrome/browser/offlinepages/OfflinePageUtils.java

Labels: M-68 offline-pages-p2p
Status: Started (was: Assigned)
Project Member

Comment 4 by bugdroid1@chromium.org, Jun 13 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/29d02cc3fb499e33f60a26899068463672ccf0b9

commit 29d02cc3fb499e33f60a26899068463672ccf0b9
Author: Pete Williamson <petewil@chromium.org>
Date: Wed Jun 13 18:24:40 2018

Better fix for  bug 829099 .

We were crashing if we ended up failing to publish a page when sharing.
An initial fix repaired it by sharing an item that was invalid in such
a way as to fail silently.

Initially I thought that the share callback needed to always be called
to continue processing and report failures.  However, all it does is to
share the item in the callback.  Therfore, a better fix is to just not
call the callback if there is some failure, as opposed to making sure
that we call it with an item which will fail to share.

Bug:  829099 
Change-Id: I9b25cb67480a822cbbe8cef1b39d687fce076af1
Reviewed-on: https://chromium-review.googlesource.com/1098382
Reviewed-by: Yafei Duan <romax@chromium.org>
Commit-Queue: Peter Williamson <petewil@chromium.org>
Cr-Commit-Position: refs/heads/master@{#566925}
[modify] https://crrev.com/29d02cc3fb499e33f60a26899068463672ccf0b9/chrome/android/java/src/org/chromium/chrome/browser/offlinepages/OfflinePageUtils.java

Status: Fixed (was: Started)

Sign in to add a comment