Closed Bug 136291 Opened 24 years ago Closed 20 years ago

nsVoidArray.h assumes sizeof(void*) == sizeof(unsigned long)

Categories

(Core :: XPCOM, defect)

Other
Other
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: pavlov, Assigned: jesup)

References

Details

Attachments

(1 file)

in nsVoidArray.h, it typedef's PtrBits to unsigned long. I'm building on a system where sizeof(void*) == 4 and sizeof(unsigned long) == 8. This is only causing warnings so far, but since it gets included in every file, it is driving me nuts.
Attached patch proposed fix — — Splinter Review
Comment on attachment 78282 [details] [diff] [review] proposed fix make that or a nor ;-)
That's some of the inherited code from content. Is there any standard type for "int long enough to contain a void*"? I'd prefer a solution that creates an int type known to be large enough for a pointer, then use that. That would generalize the solution. I'm certain there are other spots in the code that rely on things like this.
Status: NEW → ASSIGNED
This is fixed by my patch in bug 312226 since it gets rid of the define compleatly.
Depends on: 312226
fixed with my patch in bug 312226
Status: ASSIGNED → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: