Closed Bug 996912 Opened 10 years ago Closed 10 years ago

[B2G] Apps will close after the user initiates a BT transfer to another phone

Categories

(Firefox OS Graveyard :: Gaia::Bluetooth, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(blocking-b2g:1.3T+, b2g-v1.3 unaffected, b2g-v1.3T verified)

VERIFIED FIXED
blocking-b2g 1.3T+
Tracking Status
b2g-v1.3 --- unaffected
b2g-v1.3T --- verified

People

(Reporter: demerick, Assigned: fabrice)

References

()

Details

(Whiteboard: 1.3tarakorun2)

Attachments

(2 files)

Attached file firewatch and logcat
Description:
After sending a file from the gallery via Bluetooth to another device the gallery app will close and the user will be taken back to the home screen.

Repro Steps:

Pre-req: Tarako (Device Under Test - DUT), a second device, and pictures in the gallery of the DUT.

1) Update a Tarako to BuildID: 20140414004001
2) Pair the DUT and the other device via Bluetooth
3) DUT: Tap 'Gallery' from the home screen
4) DUT: Tap any of the pictures in the gallery
5) DUT: Tap the 'share' icon in the bottom middle
6) DUT: Tap 'Bluetooth transfer' and then tap the paired device

Actual:
The gallery app closes and the user is brought back to the home screen

Expected:
Device Under Test returns to the photo selected in the Gallery

1.3T Environmental Variables:
Device: Tarako 1.3T MOZ
BuildID: 20140414004001
Gaia: 0e7f21e61625b75a9149480cd5a259211549f020
Gecko: 3b02811c314a
Version: 28.1
Firmware Version: sp6821

Repro frequency: 100%
Link to failed test case: https://moztrap.mozilla.org/manage/case/8755/
See attached: video, logcat, firewatch

Video URL: http://youtu.be/5cP47EPfpBU
This issue does not reproduce on the Buri 1.3 MOZ RIL.

1.3 Environmental Variables:
Device: Buri 1.3 MOZ
BuildID: 20140414004002
Gaia: 8b92c56267fe50772095f1f25d6cc1f9c9966eb4
Gecko: 3e26908fca71
Version: 28.0
Firmware Version: v1.2-device.cfg

After initiating a BT transfer from the gallery the user is brought back to the selected photo.
See Also: → 994433
    It looks like not related to OOM. But security (no bluetooth permission)?


    02-28 04:04:03.740 I/Gecko   ( 1131): ######################## BrowserElementChildPreload.js loaded
    02-28 04:04:06.180 I/Gecko   (   83): Security problem: Content process does not have `app://bluetooth.gaiamobile.org/manifest.webapp'.  It will be killed.
    02-28 04:04:06.190 I/Gecko   (   83): [Parent 83] WARNING: waitpid failed pid:1131 errno:10: file ../../../gecko/ipc/chromium/src/base/process_util_posix.cc, line 254
    02-28 04:04:06.190 I/Gecko   (   83): Security problem: Content process does not have `app://bluetooth.gaiamobile.org/manifest.webapp'.  It will be killed.
    02-28 04:04:06.200 I/Gecko   (   83): 
    02-28 04:04:06.200 I/Gecko   (   83): ###!!! [Parent][MessageChannel] Error: Channel error: cannot send/recv
    02-28 04:04:06.200 I/Gecko   (   83): 
    02-28 04:04:06.210 I/Gecko   (   83):
It seems not only happen on Gallery but also Music file share.
blocking-b2g: --- → 1.3T?
Sorry, it looks like not related to permission. But assert in APP_PROCESS_MANIFEST_URL, that's why we saw the log prints URL instead of permission name.

gecko/dom/ipc/AppProcessChecker.cpp:118
mozilla::AssertAppProcess (aActor=0x4912fc00, aType=mozilla::ASSERT_APP_PROCESS_MANIFEST_URL, aCapability=0xbed53520 "app://bluetooth.gaiamobile.org/manifest.webapp")
Summary: [B2G][Bluetooth][Gallery] The gallery app will close after the user initiates a BT transfer to another phone → [B2G][Gallery] The gallery app will close after the user initiates a BT transfer to another phone
Fabrice,
Any suggestion for this bug?
Flags: needinfo?(fabrice)
====== log ====== 
I/Gecko   (  715): NeckoParent::AllocPRemoteOpenFile: FATAL error: app without webapps-manage permission is requesting file '/data/local/webapps/bluetooth.gaiamobile.org/application.zip' but is only allowed to open its own application.zip at /data/local/webapps/gallery.gaiamobile.org/application.zip: KILLING CHILD PROCESS
I/Gecko   (  715): 
I/Gecko   (  715): ###!!! [Parent][DispatchAsyncMessage] Error: Value error: message was deserialized, but contained an illegal value
I/Gecko   (  715): 
I/Gecko   (  715): [Parent 715] WARNING: waitpid failed pid:882 errno:10: file ../../../gecko/ipc/chromium/src/base/process_util_posix.cc, line 254
I/Gecko   (  715): 
I/Gecko   (  715): ###!!! [Parent][MessageChannel] Error: Channel error: cannot send/recv

===== build ======
Gaia      718a06816327fcb6a18095f677cfff4b86adc292
Gecko     https://hg.mozilla.org/releases/mozilla-b2g28_v1_3t/rev/7e764399b4fc
BuildID   20140415164003
Version   28.1


The issue here is relative with "KILLING CHILD PROCESS". All of user story about activity request will be happened. Such as, Gallery --> share picture via SMS/Email/BT.., I got the same error log about "KILLING CHILD PROCESS".
(In reply to Ian Liu [:ianliu] from comment #7)
> The issue here is relative with "KILLING CHILD PROCESS". All of user story
> about activity request will be happened. Such as, Gallery --> share picture
> via SMS/Email/BT.., I got the same error log about "KILLING CHILD PROCESS".
Yes, i noticed this. This is why I tried to ask Fabrice, because I'm not familiar with AppProcessChecker.cpp.
Summary: [B2G][Gallery] The gallery app will close after the user initiates a BT transfer to another phone → [B2G][Gallery]Security problem: Content process does not have `app://bluetooth.gaiamobile.org/manifest.webapp'
Summary: [B2G][Gallery]Security problem: Content process does not have `app://bluetooth.gaiamobile.org/manifest.webapp' → [B2G][Gallery] The gallery app will close after the user initiates a BT transfer to another phone
(In reply to Ian Liu [:ianliu] from comment #7)
> ====== log ====== 
> I/Gecko   (  715): NeckoParent::AllocPRemoteOpenFile: FATAL error: app
> without webapps-manage permission is requesting file
> '/data/local/webapps/bluetooth.gaiamobile.org/application.zip' but is only
> allowed to open its own application.zip at
> /data/local/webapps/gallery.gaiamobile.org/application.zip: KILLING CHILD
> PROCESS
> I/Gecko   (  715): 
> I/Gecko   (  715): ###!!! [Parent][DispatchAsyncMessage] Error: Value error:
> message was deserialized, but contained an illegal value
> I/Gecko   (  715): 
> I/Gecko   (  715): [Parent 715] WARNING: waitpid failed pid:882 errno:10:
> file ../../../gecko/ipc/chromium/src/base/process_util_posix.cc, line 254
> I/Gecko   (  715): 
> I/Gecko   (  715): ###!!! [Parent][MessageChannel] Error: Channel error:
> cannot send/recv
> 
> ===== build ======
> Gaia      718a06816327fcb6a18095f677cfff4b86adc292
> Gecko    
> https://hg.mozilla.org/releases/mozilla-b2g28_v1_3t/rev/7e764399b4fc
> BuildID   20140415164003
> Version   28.1
> 
> 
> The issue here is relative with "KILLING CHILD PROCESS". All of user story
> about activity request will be happened. Such as, Gallery --> share picture
> via SMS/Email/BT.., I got the same error log about "KILLING CHILD PROCESS".
This also happened sometimes but it's a different symptom as I mentioned in Comment 2.
Change title to apps instead of 'Gallery', since there are multiple apps which uses Bluetooth File Transfer will be closed.
Summary: [B2G][Gallery] The gallery app will close after the user initiates a BT transfer to another phone → [B2G] Apps will close after the user initiates a BT transfer to another phone
Don't think a window is going to help here unless we think this was due to something that landed on 3/29 or later. We also don't really have enough devices right now to do streamlined windows on tarako right now.
blocking-b2g: 1.3T? → 1.3T+
I'm looking into the error from comment 5 since I can reproduce, but comment 7 is a different one. Please file another bug with STR.
Flags: needinfo?(fabrice)
Gene, this is the same issue we had with system messages: we get the Unregister for IAC after we close the frame, but here we don't kill the process.

The comment refers to the same bug 988142 that we filed for system message. I'm fine to either split that to a new bug or update 988142 to make it clear that we'll need to fix the IAC code too.
Assignee: nobody → fabrice
Attachment #8407914 - Flags: review?(gene.lian)
Attachment #8407914 - Flags: review?(gene.lian) → review+
Since this seems to be urgent, I directly land this after reviewing. Some alignment are fixed as well.

https://hg.mozilla.org/integration/b2g-inbound/rev/39b6e5552082
https://hg.mozilla.org/mozilla-central/rev/39b6e5552082
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Verified fixed in todays build

1.3t Environmental Variables:
Device: Tarako 1.3t
BuildID: 20140428014001
Gaia: 8895b180ed636069473703d0e7b73086989601ce
Gecko: 7caf4b5abfce
Version: 28.1
Firmware Version: sp6821
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.