Closed Bug 783520 Opened 8 years ago Closed 8 years ago

[b2g-bluetooth] follow-up to bug 730992 (event codegen and value initialization)


(Core :: DOM: Device Interfaces, defect)

Gonk (Firefox OS)
Not set





(Reporter: echou, Assigned: echou)




(1 file, 2 obsolete files)

1. mPasskey & mUuid are not initialized in create() of BluetoothPairingEvent.
2. Use event codegen to implement BluetoothPairingEvent? 

(According to comment:
Assignee: nobody → echou
About item (1), I'll separate BluetoothPairingEvent into two events. One contains deviceAddress & uuid, the other one contains deviceAddress & passkey.
Used event generator to create BluetoothPairingEvent and BluetoothAuthorizeEvent & avoid passing non-initialized or no-value property in an event.
Attachment #653701 - Flags: review?(kyle)
Redundant modification removed.
Attachment #653701 - Attachment is obsolete: true
Attachment #653701 - Flags: review?(kyle)
Attachment #653702 - Flags: review?(kyle)
Comment on attachment 653702 [details] [diff] [review]
v1: used codegen and add BluetoothAuthorizeEvent

Review of attachment 653702 [details] [diff] [review]:

::: dom/bluetooth/BluetoothAdapter.cpp
@@ +339,5 @@
> +    e->InitBluetoothPairingEvent(NS_LITERAL_STRING("requestconfirmation"),
> +                                 false,
> +                                 false,
> +                                 arr[0].value().get_nsString(),
> +                                 arr[1].value().get_uint32_t());

Nit: Might want to put NS_ASSERTION checks on array length and value types.
Attachment #653702 - Flags: review?(kyle) → review+
Used NS_ASSERTION to verify parameter length and type.
Attachment #653702 - Attachment is obsolete: true
Keywords: checkin-needed
This patch was uploaded to inbound yesterday (See comment 7), but has not been merged to m-c. So added the "checkin-needed" label to notify.
Patches aren't checked in a second time to mozilla-central - someone just has to manually merge inbound to mozilla-central (which typically happens once a day). We have to wait for a green PGO run (which doesn't happen on every push), which when combined with discovering bustage/backing that out/waiting for green again (PGO runs take up to 4-5 hours), can mean merges are often delayed.

When this merges the mozilla-central changeset will be posted in the bug, and the bug marked fixed :-)
Keywords: checkin-needed
Thank you, Ed. My bad. I did understand how this worked. I asked this question is because this morning I found there's a patch already in m-c, was submitted later than mine. However, I just checked again and couldn't find that patch anymore. I must be so tired. :P

Thanks again. :)
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla17
You need to log in before you can comment on or make changes to this bug.