projects
/
platform
/
upstream
/
libSkiaSharp.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
781d582
)
Avoid unnecessary comparison if both Typeface are NULL
author
jin.a.yang
<jin.a.yang@intel.com>
Wed, 17 Jun 2015 11:47:18 +0000
(
04:47
-0700)
committer
Commit bot
<commit-bot@chromium.org>
Wed, 17 Jun 2015 11:47:18 +0000
(
04:47
-0700)
BUG=skia:
Review URL: https://codereview.chromium.org/
1177833004
src/core/SkTypeface.cpp
patch
|
blob
|
history
diff --git
a/src/core/SkTypeface.cpp
b/src/core/SkTypeface.cpp
index
fcbb745
..
2c7db68
100644
(file)
--- a/
src/core/SkTypeface.cpp
+++ b/
src/core/SkTypeface.cpp
@@
-107,7
+107,7
@@
uint32_t SkTypeface::UniqueID(const SkTypeface* face) {
}
bool SkTypeface::Equal(const SkTypeface* facea, const SkTypeface* faceb) {
- return SkTypeface::UniqueID(facea) == SkTypeface::UniqueID(faceb);
+ return
facea == faceb ||
SkTypeface::UniqueID(facea) == SkTypeface::UniqueID(faceb);
}
///////////////////////////////////////////////////////////////////////////////