Closed Bug 336118 Opened 18 years ago Closed 7 years ago

API extension needed for getting Unsigned int preferences

Categories

(Core :: Preferences: Backend, defect)

defect
Not set
normal

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: philipp, Unassigned)

Details

Many preferences have no possible negative values, even when defaulted, and hence using an accessor that returns a negative value merely adds complexity and the possibility of missing/inadequate bounds checking.

It also means that the potential for coding mixing signed and unsigned variables being manipulated and/or compared is introduced (with the accompanying sign mismatches on comparisons).

Having an accessor/convenience function for unsigned values would simplify coding.
Assignee: mscott → prefs
Component: General → Preferences: Backend
Product: Thunderbird → Core
QA Contact: general
Version: 1.5 → Trunk
(Filter "spam" on 'prefs-nobody-20080612'.)
Assignee: prefs → nobody
QA Contact: prefs
QA Contact: preferences → preferences-backend
The Preferences class has uint getters/setters. nsIPrefBranch doesn't, but it's mostly used from JavaScript code, which doesn't have uints. So I think the current situation is good enough.
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.