diff options
author | Alan Coopersmith <alan.coopersmith@oracle.com> | 2023-04-01 13:02:50 -0700 |
---|---|---|
committer | Alan Coopersmith <alan.coopersmith@oracle.com> | 2023-04-01 13:02:50 -0700 |
commit | 15f75aa8e6578cd2a27cadfc11e31b58e2fc6683 (patch) | |
tree | ce954f375246067725a5594dc41693f5be76d892 | |
parent | 11fa7c2d7c5c668ea921f1dbc6b70e97e3535afe (diff) |
Remove unused function findIndex
Found by cppcheck
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-rw-r--r-- | fonttosfnt.h | 1 | ||||
-rw-r--r-- | struct.c | 15 |
2 files changed, 0 insertions, 16 deletions
diff --git a/fonttosfnt.h b/fonttosfnt.h index 63852c5..5a9decc 100644 --- a/fonttosfnt.h +++ b/fonttosfnt.h @@ -165,7 +165,6 @@ BitmapPtr makeBitmap(StrikePtr, int, IndexSubTablePtr makeIndexSubTables(StrikePtr, CmapPtr); int fontIndex(FontPtr, int); CmapPtr makeCmap(FontPtr); -int findIndex(CmapPtr, int); int findCode(CmapPtr, int); BitmapPtr strikeBitmapIndex(StrikePtr, CmapPtr, int); int strikeMaxWidth(StrikePtr); @@ -390,21 +390,6 @@ makeCmap(FontPtr font) } int -findIndex(CmapPtr cmap_head, int code) -{ - CmapPtr cmap; - cmap = cmap_head; - while(cmap) { - if(cmap->endCode > code) - return -1; - if(cmap->startCode <= code) - return cmap->index + code - cmap->startCode; - cmap = cmap->next; - } - return -1; -} - -int findCode(CmapPtr cmap_head, int index) { if(index < 0 || index > cmap_head->maxindex) |