minor fix
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@118 4cde692c-a291-49d1-8350-778aa11640f8
diff --git a/Lib/fontTools/ttLib/sfnt.py b/Lib/fontTools/ttLib/sfnt.py
index 2fdeb99..4a4a7e7 100644
--- a/Lib/fontTools/ttLib/sfnt.py
+++ b/Lib/fontTools/ttLib/sfnt.py
@@ -213,7 +213,7 @@
while x:
x = x >> 1
exponent = exponent + 1
- return exponent - 1
+ return max(exponent - 1, 0)
def getsearchrange(n):
diff --git a/Lib/fontTools/ttLib/tables/_p_o_s_t.py b/Lib/fontTools/ttLib/tables/_p_o_s_t.py
index 273de79..82fdb49 100644
--- a/Lib/fontTools/ttLib/tables/_p_o_s_t.py
+++ b/Lib/fontTools/ttLib/tables/_p_o_s_t.py
@@ -129,7 +129,7 @@
index = standardGlyphOrder.index(psName)
else:
index = 258 + len(self.extraNames)
- extraNames.append(psName)
+ self.extraNames.append(psName)
indices.append(index)
if ttLib.endian <> "big":
indices.byteswap()