diff options
Diffstat (limited to 'src/fontpack.h')
-rw-r--r-- | src/fontpack.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/fontpack.h b/src/fontpack.h index 5d592822..d86de945 100644 --- a/src/fontpack.h +++ b/src/fontpack.h | |||
@@ -131,7 +131,8 @@ struct Impl_FontSpec { | |||
131 | }; | 131 | }; |
132 | 132 | ||
133 | iLocalDef int scaleType_FontSpec(enum iFontSize sizeId) { | 133 | iLocalDef int scaleType_FontSpec(enum iFontSize sizeId) { |
134 | return sizeId / contentRegular_FontSize; | 134 | iAssert(sizeId >= 0 && sizeId < max_FontSize); |
135 | return sizeId < contentRegular_FontSize ? 0 : 1; | ||
135 | } | 136 | } |
136 | 137 | ||
137 | /*----------------------------------------------------------------------------------------------*/ | 138 | /*----------------------------------------------------------------------------------------------*/ |