diff options
author | Keith Packard <keithp@neko.keithp.com> | 2006-09-06 17:45:40 -0700 |
---|---|---|
committer | Keith Packard <keithp@neko.keithp.com> | 2006-09-06 17:45:40 -0700 |
commit | c3796ac6061373bcf0276a931036987c01741215 (patch) | |
tree | 6ff4c267ad26b720950edff9c65fcc23986b03f8 /src | |
parent | 08bef687018f2391c2f2b6fc3849878c121b67dd (diff) |
Charset hashing depended on uniqueness of leaves.
Charset hashing actually use the value of the leaf pointers, which is
clearly wrong, especially now that charsets are not shared across multiple
font directories.
Diffstat (limited to 'src')
-rw-r--r-- | src/fccharset.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/fccharset.c b/src/fccharset.c index 1c2e2eac..5da13128 100644 --- a/src/fccharset.c +++ b/src/fccharset.c @@ -1064,8 +1064,8 @@ FcCharSetHash (FcCharSet *fcs) int i; /* hash in leaves */ - for (i = 0; i < fcs->num * (int) (sizeof (FcCharLeaf *) / sizeof (FcChar32)); i++) - hash = ((hash << 1) | (hash >> 31)) ^ (FcChar32)(FcCharSetLeaf(fcs, i)->map); + for (i = 0; i < fcs->num; i++) + hash = ((hash << 1) | (hash >> 31)) ^ FcCharLeafHash (FcCharSetLeaf(fcs,i)); /* hash in numbers */ for (i = 0; i < fcs->num; i++) hash = ((hash << 1) | (hash >> 31)) ^ *FcCharSetNumbers(fcs); |