Closed
Bug 794023
Opened 12 years ago
Closed 12 years ago
NECKO_UNKNOWN_APP should use std::numeric_limits
Categories
(Core :: Networking, defect)
Core
Networking
Tracking
()
RESOLVED
FIXED
mozilla18
People
(Reporter: mounir, Assigned: jduell.mcbugs)
References
Details
Attachments
(2 obsolete files)
Using 4294967295 will warn and the netwerk/ seems to be warning-free (so it's failing the build). I have no idea why we should still use PR_UINT32_MAX when we cas simply use std::numeric_limits<uint32_t>::max(). Which in addition of being readable, doesn't warn.
Jason, could you review the fix and ehsan, could you confirm that it might be better to switch PR_UINT32_MAX to numeric_limits?
Attachment #664428 -
Flags: review?(jduell.mcbugs)
Attachment #664428 -
Flags: feedback?(ehsan)
Comment 1•12 years ago
|
||
Comment on attachment 664428 [details] [diff] [review]
Patch
Yes please!
Attachment #664428 -
Flags: feedback?(ehsan) → feedback+
Assignee | ||
Comment 2•12 years ago
|
||
Comment on attachment 664428 [details] [diff] [review]
Patch
Review of attachment 664428 [details] [diff] [review]:
-----------------------------------------------------------------
This was just copied and pasted from caps/idl/nsIScriptSecurityManager.idl's "const unsigned long UNKNOWN_APP_ID = 4294967295;", so you should open a bug to fix that site too.
Attachment #664428 -
Flags: review?(jduell.mcbugs) → review+
Comment 3•12 years ago
|
||
NSPR doesn't use C++ and therefore can't use numeric_limits
In bug 756648 comment 31 I did ask that this file does not use this literal, I'm annoyed that my review comment was ignored.
Anyway you should now remove the comment about PR_UINT32_MAX, that is obvious now that the file uses numeric_limits
Assignee | ||
Comment 4•12 years ago
|
||
This just also uncomments the uses of NECKO_UNKNOWN_APP.
Applies on top of my patch for bug 786299.
Delegating review to mounir...
Assignee: mounir → jduell.mcbugs
Attachment #664428 -
Attachment is obsolete: true
Attachment #665764 -
Flags: review?(mounir)
Reporter | ||
Updated•12 years ago
|
Flags: in-testsuite-
Summary: NECKO_UNKNOWN_APP_ID should use std::numeric_limits → NECKO_UNKNOWN_APP should use std::numeric_limits
Target Milestone: --- → mozilla18
Reporter | ||
Comment 5•12 years ago
|
||
Comment on attachment 665764 [details] [diff] [review]
v2: uncomments uses of NECKO_UNKNOWN_APP, too
I pushed the obsoleted patch and uncommented something I commented yesterday to fix a build bustage. I haven't found the other line you uncommented Jason so I believe this is in your patch queue.
Attachment #665764 -
Flags: review?(mounir)
Reporter | ||
Comment 6•12 years ago
|
||
Assignee | ||
Comment 7•12 years ago
|
||
Comment on attachment 665764 [details] [diff] [review]
v2: uncomments uses of NECKO_UNKNOWN_APP, too
OK, no worries--code will go in a different bug.
Attachment #665764 -
Attachment is obsolete: true
Comment 8•12 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•