Closed Bug 1123536 Opened 11 years ago Closed 11 years ago

Use NS_WARN_IF() while doing Convert() in BluetoothHALHelpers.

Categories

(Firefox OS Graveyard :: Bluetooth, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WORKSFORME

People

(Reporter: brsun, Assigned: wiwang)

Details

(Whiteboard: good first bug)

It would be better to use |NS_WARN_IF()| in each |Convert()| while checking valid values.
(In reply to Bruce Sun [:brsun] from comment #0) > It would be better to use |NS_WARN_IF()| in each |Convert()| while checking > valid values. You should call NS_WARN_IF around the actual test that fails, not every single call to Convert. That would just put tons of noise into the log. If you want a more meaningful error message, add some logging to say which command, response or notification failed.
(In reply to Bruce Sun [:brsun] from comment #0) > It would be better to use |NS_WARN_IF()| in each |Convert()| while checking > valid values. The wordings in comment 0 should be rephrased as following: ...to use |NS_WARN_IF()| in each |Convert()| while checking INVALID values.
Is there anything missing? I wasn't aware of that.
I see. I probably didn't take logging serious in the beginning. :( I'm not sure is it's worth fixing it. HAL is going away soon. I wouldn't expect it to be present in v3.
(In reply to Thomas Zimmermann [:tzimmermann] [:tdz] from comment #5) > I see. I probably didn't take logging serious in the beginning. :( > > I'm not sure is it's worth fixing it. HAL is going away soon. I wouldn't > expect it to be present in v3. Maybe this will be a good-first-bug for new hire.
Whiteboard: good first bug
Resolved as WFM since bug 1187872 removes HAL backend.
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.