nsView.cpp:990:32: warning: format ‘%p’ expects argument of type ‘void*’, but argument 5 has type ‘nsIFrame*’ [-Wformat]

RESOLVED FIXED in mozilla14

Status

()

Core
Event Handling
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: dholbert, Assigned: dholbert)

Tracking

(Blocks: 1 bug)

Trunk
mozilla14
x86_64
Linux
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Assignee)

Description

5 years ago
Created attachment 610612 [details] [diff] [review]
trivial fix

Build warning:
{
nsView.cpp:990:32: warning: format ‘%p’ expects argument of type ‘void*’, but argument 5 has type ‘nsIFrame*’ [-Wformat]
}

...which points to this code:
> 989   fprintf(out, " z=%d vis=%d frame=%p <\n",
> 990           mZIndex, mVis, mFrame);
http://mxr.mozilla.org/mozilla-central/source/view/src/nsView.cpp#989
which was added in bug 703260.

This just wants some static_cast<void*>() love (which is what we use elsewhere to suppress this warning).  Silly [f]printf.
Attachment #610612 - Flags: review?(bugs)

Updated

5 years ago
Attachment #610612 - Flags: review?(bugs) → review+
(Assignee)

Comment 1

5 years ago
https://hg.mozilla.org/integration/mozilla-inbound/rev/176df86aa16e
Target Milestone: --- → mozilla14

Comment 2

5 years ago
https://hg.mozilla.org/mozilla-central/rev/176df86aa16e
Status: ASSIGNED → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.