Closed
Bug 1116458
Opened 9 years ago
Closed 9 years ago
Some functions of nsINetworkService cannot be called interleavingly.
Categories
(Firefox OS Graveyard :: Wifi, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
2.2 S3 (9jan)
People
(Reporter: hchang, Assigned: hchang)
References
Details
Attachments
(1 file, 1 obsolete file)
14.56 KB,
patch
|
Details | Diff | Splinter Review |
nsINetworkService provides a set of functions about networking but some of them which require netd command chain cannot be called interleavingly. That means, one function has to be called after the previous one is called back. It is inconvenient for calling nsINetworkSerive functions in a row.
Assignee | ||
Updated•9 years ago
|
Assignee: nobody → hchang
Assignee | ||
Comment 1•9 years ago
|
||
Assignee | ||
Updated•9 years ago
|
Attachment #8543843 -
Flags: review?(dlee)
Comment 2•9 years ago
|
||
Comment on attachment 8543843 [details] [diff] [review] Bug1116458.patch Review of attachment 8543843 [details] [diff] [review]: ----------------------------------------------------------------- Looks good, thanks ::: dom/system/gonk/NetworkUtils.cpp @@ +126,1 @@ > I think we need to clear this when NetworkUtils is destroyed @@ +999,5 @@ > MOZ_ASSERT(!gWifiTetheringParms); > gWifiTetheringParms = new NetworkParams(aChain->getParams()); > } > postMessage(aChain->getParams(), aResult); > + finalizeSuccess(aChain, aResult); Is it possible we move this into PostMessage and check the |aResult| value ? Only call finalize when result is success. I am not sure if there is any chance that result is success but we don't have to call finalize
Attachment #8543843 -
Flags: review?(dlee) → review+
Assignee | ||
Comment 3•9 years ago
|
||
Thanks for your review! (In reply to Dimi Lee[:dimi][:dlee] from comment #2) > Comment on attachment 8543843 [details] [diff] [review] > Bug1116458.patch > > Review of attachment 8543843 [details] [diff] [review]: > ----------------------------------------------------------------- > > Looks good, thanks > > ::: dom/system/gonk/NetworkUtils.cpp > @@ +126,1 @@ > > > > I think we need to clear this when NetworkUtils is destroyed > > @@ +999,5 @@ > > MOZ_ASSERT(!gWifiTetheringParms); > > gWifiTetheringParms = new NetworkParams(aChain->getParams()); > > } > > postMessage(aChain->getParams(), aResult); > > + finalizeSuccess(aChain, aResult); > > Is it possible we move this into PostMessage and check the |aResult| value ? > Only call finalize when result is success. I am not sure if there is any > chance > that result is success but we don't have to call finalize Since there's no standard way to tell if a operation is successful or not (some uses mRet and some uses mSuccess), it's difficult to knwo when we should call to finalize in PostMessage whereas xxxxSuccess explicitly suggests success. By the way, I forgot to add finalizeSuccess to updateUpStreamSuccess
Assignee | ||
Comment 4•9 years ago
|
||
Assignee | ||
Comment 5•9 years ago
|
||
https://treeherder.mozilla.org/#/jobs?repo=try&revision=c6e94e477bc3
Assignee | ||
Updated•9 years ago
|
Attachment #8543843 -
Attachment is obsolete: true
Assignee | ||
Updated•9 years ago
|
Keywords: checkin-needed
Comment 6•9 years ago
|
||
https://hg.mozilla.org/integration/b2g-inbound/rev/67ea86c1f2e9
Keywords: checkin-needed
Comment 7•9 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/67ea86c1f2e9
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → 2.2 S3 (9jan)
You need to log in
before you can comment on or make changes to this bug.
Description
•