Closed Bug 1159455 Opened 9 years ago Closed 9 years ago

APZ debug logging format specifiers need cleanup

Categories

(Core :: Panning and Zooming, defect)

All
Gonk (Firefox OS)
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla40
Tracking Status
firefox40 --- fixed

People

(Reporter: kats, Assigned: kats)

Details

Attachments

(1 file, 1 obsolete file)

The printf format specifiers fail to compile on some platforms.
Attached patch Patch (obsolete) — Splinter Review
Also removed \n from NS_WARNINGs and fixed APZES_LOG. Try push with these changes and all the debug logging enabled is at https://treeherder.mozilla.org/#/jobs?repo=try&revision=7db7071a1c16
Attachment #8598906 - Flags: review?(botond)
Comment on attachment 8598906 [details] [diff] [review]
Patch

Review of attachment 8598906 [details] [diff] [review]:
-----------------------------------------------------------------

I think we need to use the PRIuSIZE macro instead of "zu", see [1].

[1] https://dxr.mozilla.org/mozilla-central/source/mfbt/SizePrintfMacros.h
Comment on attachment 8598906 [details] [diff] [review]
Patch

Makes sense, I'll update the patch. I'm wondering how it compiled successfully on windows though (in the try push).
Attachment #8598906 - Flags: review?(botond)
(In reply to Kartikaya Gupta (email:kats@mozilla.com) from comment #3)
> Makes sense, I'll update the patch. I'm wondering how it compiled
> successfully on windows though (in the try push).

MOZ_FORMAT_PRINTF expands to nothing on MSVC [1].

[1] http://mxr.mozilla.org/mozilla-central/source/xpcom/base/nscore.h?rev=7e4e5e971d95#169
Attachment #8599370 - Flags: review?(botond) → review+
https://hg.mozilla.org/mozilla-central/rev/0cca6dda7467
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla40
You need to log in before you can comment on or make changes to this bug.