If you think a bug might affect users in the 57 release, please set the correct tracking and status flags for Release Management.

Variant.h(152) : warning C4244: '=' : conversion from 'PRInt64' to 'PRInt32', possible loss of data

RESOLVED FIXED in mozilla1.9.3a1

Status

()

Toolkit
Storage
RESOLVED FIXED
8 years ago
8 years ago

People

(Reporter: mak, Assigned: mak)

Tracking

Trunk
mozilla1.9.3a1
All
Windows XP
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Assignee)

Description

8 years ago
i always see this warning while compiling with mc

mozilla/storage/Variant.h(152) : warning C4244: '=' : conversion from 'PRInt64' to 'PRInt32', possible loss of data

it should just need a cast, but it's annoying
That's kinda annoying since I'm doing the bounds checking.  If we change that line to |*_result = PRInt32(aValue);| does the error go away?

http://mxr.mozilla.org/mozilla-central/source/storage/src/Variant.h#143
I don't know why gcc let you get away with that. static_cast is the way to go I think.
(Assignee)

Comment 3

8 years ago
Created attachment 405079 [details] [diff] [review]
patch v1.0
Assignee: nobody → mak77
Status: NEW → ASSIGNED
Attachment #405079 - Flags: review?(sdwilsh)
Comment on attachment 405079 [details] [diff] [review]
patch v1.0

r=sdwilsh
Attachment #405079 - Flags: review?(sdwilsh) → review+
(Assignee)

Comment 5

8 years ago
http://hg.mozilla.org/mozilla-central/rev/cd20b8c48924
Status: ASSIGNED → RESOLVED
Last Resolved: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla1.9.3a1
You need to log in before you can comment on or make changes to this bug.