[poppler] poppler/poppler: ArthurOutputDev.cc, 1.8,
1.9 CairoFontEngine.cc, 1.16, 1.17
Marco Pesenti Gritti
marco at freedesktop.org
Fri Sep 16 11:11:16 PDT 2005
Update of /cvs/poppler/poppler/poppler
In directory gabe:/tmp/cvs-serv2092/poppler
Modified Files:
ArthurOutputDev.cc CairoFontEngine.cc
Log Message:
2005-09-16 Marco Pesenti Gritti <mpg at redhat.com>
* poppler/ArthurOutputDev.cc:
* poppler/CairoFontEngine.cc:
* poppler/TextOutputDev.cc:
* poppler/UnicodeMap.cc:
Use mallocn when possible
Index: ArthurOutputDev.cc
===================================================================
RCS file: /cvs/poppler/poppler/poppler/ArthurOutputDev.cc,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- ArthurOutputDev.cc 4 Aug 2005 10:15:23 -0000 1.8
+++ ArthurOutputDev.cc 16 Sep 2005 18:11:14 -0000 1.9
@@ -378,7 +378,7 @@
break;
case fontCIDType2:
n = ((GfxCIDFont *)gfxFont)->getCIDToGIDLen();
- codeToGID = (Gushort *)gmalloc(n * sizeof(Gushort));
+ codeToGID = (Gushort *)gmallocn(n, sizeof(Gushort));
memcpy(codeToGID, ((GfxCIDFont *)gfxFont)->getCIDToGID(),
n * sizeof(Gushort));
if (!(fontFile = m_fontEngine->loadTrueTypeFont(
Index: CairoFontEngine.cc
===================================================================
RCS file: /cvs/poppler/poppler/poppler/CairoFontEngine.cc,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -d -r1.16 -r1.17
--- CairoFontEngine.cc 15 Sep 2005 22:09:50 -0000 1.16
+++ CairoFontEngine.cc 16 Sep 2005 18:11:14 -0000 1.17
@@ -112,7 +112,7 @@
enc = ((Gfx8BitFont *)gfxFont)->getEncoding();
- codeToGID = (Gushort *)gmalloc(256 * sizeof(int));
+ codeToGID = (Gushort *)gmallocn(256, sizeof(int));
codeToGIDLen = 256;
for (i = 0; i < 256; ++i) {
codeToGID[i] = 0;
@@ -125,7 +125,7 @@
case fontCIDType2:
n = ((GfxCIDFont *)gfxFont)->getCIDToGIDLen();
codeToGIDLen = n;
- codeToGID = (Gushort *)gmalloc(n * sizeof(Gushort));
+ codeToGID = (Gushort *)gmallocn(n, sizeof(Gushort));
memcpy(codeToGID, ((GfxCIDFont *)gfxFont)->getCIDToGID(),
n * sizeof(Gushort));
/* Fall through */
More information about the poppler
mailing list