Note: There are a few cases of duplicates in user autocompletion which are being worked on.

FT2FontEntry spews unwanted warnings when (optional) font tables are absent

RESOLVED FIXED in mozilla15

Status

()

Core
Graphics: Text
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: jfkthame, Assigned: jfkthame)

Tracking

unspecified
mozilla15
All
Android
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Assignee)

Description

5 years ago
Created attachment 626477 [details] [diff] [review]
patch, don't use NS_ENSURE_TRUE for normal control flow

FT2FontEntry::GetFontTable uses NS_ENSURE_TRUE to return a failure code if the requested table is not present (so FT_Load_Sfnt_Table failed). However, it's perfectly normal for shaping code to request optional tables (such as 'kern' or the OpenType Layout tables); their absence is not an error or anomaly that deserves a warning message.

So we should use a simple "if (...) return NS_ERROR_FAILURE" instead of NS_ENSURE_TRUE here, to avoid spamming the console with these warnings.
Attachment #626477 - Flags: review?(jdaggett)

Comment 1

5 years ago
Comment on attachment 626477 [details] [diff] [review]
patch, don't use NS_ENSURE_TRUE for normal control flow

This is fine but I don't think the comment is needed.
Attachment #626477 - Flags: review?(jdaggett) → review+
(Assignee)

Comment 2

5 years ago
OK, pushed without added comment.
https://hg.mozilla.org/integration/mozilla-inbound/rev/1865549541b7
Target Milestone: --- → mozilla15

Comment 3

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