libxfont: Changes to 'upstream-unstable'

2016-11-22 Thread Emilio Pozuelo Monfort
 .gitignore  |3 
 Makefile.am |  122 -
 configure.ac|   42 -
 include/X11/fonts/.gitignore|2 
 include/X11/fonts/bufio.h   |2 
 include/X11/fonts/fontconf.h.in |   49 --
 include/X11/fonts/fontmisc.h|2 
 include/X11/fonts/fontutil.h|2 
 include/X11/fonts/libxfont2.h   |  163 +++
 include/libxfontint.h   |  130 ++
 m4/attributes.m4|  283 
 src/FreeType/Makefile.am|   15 --
 src/FreeType/ft.h   |2 
 src/FreeType/ftenc.c|1 
 src/FreeType/ftfuncs.c  |3 
 src/FreeType/fttools.c  |1 
 src/FreeType/xttcap.c   |1 
 src/Makefile.am |   68 -
 src/bitmap/Makefile.am  |   29 
 src/bitmap/bdfread.c|1 
 src/bitmap/bdfutils.c   |1 
 src/bitmap/bitmap.c |1 
 src/bitmap/bitmapfunc.c |1 
 src/bitmap/bitmaputil.c |1 
 src/bitmap/bitscale.c   |8 -
 src/bitmap/fontink.c|1 
 src/bitmap/pcfread.c|1 
 src/bitmap/pcfwrite.c   |7 
 src/bitmap/snfread.c|1 
 src/builtins/Makefile.am|   17 --
 src/builtins/dir.c  |1 
 src/builtins/file.c |1 
 src/builtins/fonts.c|1 
 src/builtins/fpe.c  |   36 ++---
 src/builtins/render.c   |1 
 src/fc/Makefile.am  |   16 --
 src/fc/fsconvert.c  |1 
 src/fc/fserve.c |  146 +++-
 src/fc/fserve.h |9 -
 src/fc/fsio.c   |2 
 src/fc/fsio.h   |2 
 src/fc/fstrans.c|4 
 src/fontfile/Makefile.am|   29 
 src/fontfile/bitsource.c|1 
 src/fontfile/bufio.c|3 
 src/fontfile/bunzip2.c  |1 
 src/fontfile/catalogue.c|   36 ++---
 src/fontfile/decompress.c   |1 
 src/fontfile/defaults.c |1 
 src/fontfile/dirfile.c  |1 
 src/fontfile/fileio.c   |1 
 src/fontfile/filewr.c   |1 
 src/fontfile/fontdir.c  |7 
 src/fontfile/fontencc.c |3 
 src/fontfile/fontfile.c |   64 -
 src/fontfile/fontscale.c|1 
 src/fontfile/gunzip.c   |1 
 src/fontfile/register.c |1 
 src/fontfile/renderers.c|3 
 src/stubs/Makefile.am   |   25 ---
 src/stubs/atom.c|  224 +++
 src/stubs/cauthgen.c|   15 --
 src/stubs/csignal.c |   15 --
 src/stubs/delfntcid.c   |   14 -
 src/stubs/errorf.c  |   14 -
 src/stubs/findoldfnt.c  |   15 --
 src/stubs/getcres.c |   15 --
 src/stubs/getdefptsize.c|   15 --
 src/stubs/getnewfntcid.c|   15 --
 src/stubs/gettime.c |   15 --
 src/stubs/initfshdl.c   |   16 --
 src/stubs/libxfontstubs.c   |  198 +++
 src/stubs/regfpefunc.c  |   32 
 src/stubs/rmfshdl.c |   16 --
 src/stubs/servclient.c  |   19 --
 src/stubs/setfntauth.c  |   15 --
 src/stubs/stfntcfnt.c   |   15 --
 src/stubs/stubs.h   |   79 ---
 src/stubs/stubsinit.c   |   82 ---
 src/util/Makefile.am|   19 --
 src/util/atom.c |  250 ---
 src/util/fontaccel.c|1 
 src/util/fontnames.c|9 -
 src/util/fontutil.c |   38 +
 src/util/fontxlfd.c |1 
 src/util/format.c   |1 
 src/util/miscutil.c |   23 ---
 src/util/patcache.c |   35 ++--
 src/util/private.c  |5 
 src/util/utilbitmap.c   |1 
 xfont.pc.in |   13 -
 xfont2.pc.in|   13 +
 92 files changed, 1417 insertions(+), 1181 deletions(-)

New commits:
commit 14488af0338191356c0177e3d0b5fa473ffbd59c
Author: Keith Packard 
Date:   Fri Dec 11 07:08:29 2015 -0800

Bump version to 2.0.1

This release just fixes some build issues with 2.0.0

Signed-off-by: Keith Packard 

diff --git a/configure.ac b/configure.ac
index a13e7bd..a555151 100644
--- a/configure.ac
+++ b/configure.ac
@@ -21,7 +21,7 @@
 
 # Initialize Autoconf
 AC_PREREQ([2.60])
-AC_INIT([libXfont2], [2.0.0],
+AC_INIT([libXfont2], [2.0.1],
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [libXfont2])
 AC_CONFIG_SRCDIR([Makefile.am])
 AC_CONFIG_HEADERS([config.h])

commit 95a40553b8f12cd9479dd4b3c531e2069c53b870
Author: Keith Packard 
Date:   Wed Dec 9 14:53:26 2015 -0800

Remove fontconf.h

This file used to advertise which font formats the library
 

libxfont: Changes to 'upstream-unstable'

2016-09-24 Thread Julien Cristau
 configure.ac   |5 
 doc/fontlib.xml|5 +++-
 src/FreeType/ftfuncs.c |   20 -
 src/FreeType/xttcap.c  |2 -
 src/bitmap/bdfread.c   |6 ++---
 src/bitmap/bdfutils.c  |4 +--
 src/bitmap/bitscale.c  |4 +++
 src/bitmap/pcfread.c   |1 
 src/fc/fserve.c|8 ++
 src/stubs/stubs.h  |   57 -
 src/util/fontxlfd.c|   10 
 11 files changed, 57 insertions(+), 65 deletions(-)

New commits:
commit 8cce9834b2e74dccad94ca0adf79ae5585e37d48
Author: Adam Jackson 
Date:   Wed Aug 31 16:19:11 2016 -0400

libXfont 1.5.2

Signed-off-by: Adam Jackson 

diff --git a/configure.ac b/configure.ac
index 640cc92..3325aa3 100644
--- a/configure.ac
+++ b/configure.ac
@@ -21,7 +21,7 @@
 
 # Initialize Autoconf
 AC_PREREQ([2.60])
-AC_INIT([libXfont], [1.5.1],
+AC_INIT([libXfont], [1.5.2],
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [libXfont])
 AC_CONFIG_SRCDIR([Makefile.am])
 AC_CONFIG_HEADERS([config.h include/X11/fonts/fontconf.h])

commit 42d85d1293b2753f3f200de0e960bacef0c973c7
Author: Jeremy Huddleston Sequoia 
Date:   Mon May 30 00:46:21 2016 -0700

fserve: Fix a buffer read overrun in _fs_client_access

https://bugs.freedesktop.org/show_bug.cgi?id=83224

Found by clang's Address Sanitizer

crac.num_auths = set_font_authorizations(&authorizations, &authlen,
 client);
/* Work around bug in xfs versions up through modular release 1.0.8
   which rejects CreateAC packets with num_auths = 0 & authlen < 4 */
if (crac.num_auths == 0) {
authorizations = padding;
authlen = 4;
} else {
authlen = (authlen + 3) & ~0x3;
}
crac.length = (sizeof (fsCreateACReq) + authlen) >> 2;
crac.acid = cur->acid;
_fs_add_req_log(conn, FS_CreateAC);
_fs_write(conn, (char *) &crac, sizeof (fsCreateACReq));
_fs_write(conn, authorizations, authlen);

In the case in the report, set_font_authorizations setup authorizations as a
34 byte buffer (and authlen set to 34 as one would expect). The following
block changed authlen to 36 to make it 4byte aligned and the final 
_fs_write()
caused us to read 36 bytes from this 34 byte buffer.

This changes the incorrect size increase to instead use _fs_write_pad which
takes care of the padding for us.

Signed-off-by: Jeremy Huddleston Sequoia 
(cherry picked from commit 6972ea08ee5b2ef1cfbdc2fcaf14f06bbd391561)

diff --git a/src/fc/fserve.c b/src/fc/fserve.c
index bbaa8bf..4fb5551 100644
--- a/src/fc/fserve.c
+++ b/src/fc/fserve.c
@@ -2850,14 +2850,12 @@ _fs_client_access (FSFpePtr conn, pointer client, Bool 
sync)
if (crac.num_auths == 0) {
authorizations = padding;
authlen = 4;
-   } else {
-   authlen = (authlen + 3) & ~0x3;
}
crac.length = (sizeof (fsCreateACReq) + authlen) >> 2;
crac.acid = cur->acid;
_fs_add_req_log(conn, FS_CreateAC);
_fs_write(conn, (char *) &crac, sizeof (fsCreateACReq));
-   _fs_write(conn, authorizations, authlen);
+   _fs_write_pad(conn, authorizations, authlen);
/* ignore reply; we don't even care about it */
conn->curacid = 0;
cur->auth_generation = client_auth_generation(client);

commit 2b09a7af9f19db886567e524f978ad393593f7c0
Author: Jeremy Huddleston Sequoia 
Date:   Sun May 29 23:37:13 2016 -0700

fserve: Silence a -Wformat warning

src/fc/fserve.c:653:32: warning: format specifies type 'int' but the 
argument has type 'CARD32' (aka 'unsigned long') [-Wformat]
   " from font server\n", rep->length);
  ^~~
1 warning generated.

Signed-off-by: Jeremy Huddleston Sequoia 
(cherry picked from commit e6009adbc89ec3e1f924bcb57b333c1c02f5e66d)

diff --git a/src/fc/fserve.c b/src/fc/fserve.c
index 92b0d53..bbaa8bf 100644
--- a/src/fc/fserve.c
+++ b/src/fc/fserve.c
@@ -631,8 +631,8 @@ fs_get_reply (FSFpePtr conn, int *error)
  */
 if (rep->length > MAX_REPLY_LENGTH)
 {
-   ErrorF("fserve: reply length %d > MAX_REPLY_LENGTH, disconnecting"
-  " from font server\n", rep->length);
+   ErrorF("fserve: reply length %ld > MAX_REPLY_LENGTH, disconnecting"
+  " from font server\n", (long)rep->length);
_fs_connection_died (conn);
*error = FSIO_ERROR;
return 0;

commit 3eddbca2690381bbbaf14adadb2679eea702095f
Author: Jeremy Huddleston Sequoia 
Date:   Sun May 29 23:34:35 2016 -0700

bitmap: Bail out on invalid input to FontFileMakeDir instead of calling 
calloc for 0 bytes

Found by clang static analysis:
Call to 'calloc' has an allocation size of 0 bytes

Signed-off-by: Jeremy Huddleston Sequoia 
(cher

libxfont: Changes to 'upstream-unstable'

2015-03-17 Thread Julien Cristau
 configure.ac  |2 
 src/bitmap/bdfread.c  |   35 +++
 src/fc/fslibos.h  |  220 --
 src/fontfile/fileio.c |5 -
 src/fontfile/filewr.c |   12 +-
 5 files changed, 152 insertions(+), 122 deletions(-)

New commits:
commit da4246c98bc51297daeec47c15181e179df94013
Author: Alan Coopersmith 
Date:   Tue Mar 17 08:12:19 2015 -0700

libXfont 1.5.1

Signed-off-by: Alan Coopersmith 

diff --git a/configure.ac b/configure.ac
index 471b266..7cb6bdf 100644
--- a/configure.ac
+++ b/configure.ac
@@ -21,7 +21,7 @@
 
 # Initialize Autoconf
 AC_PREREQ([2.60])
-AC_INIT([libXfont], [1.5.0],
+AC_INIT([libXfont], [1.5.1],
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [libXfont])
 AC_CONFIG_SRCDIR([Makefile.am])
 AC_CONFIG_HEADERS([config.h include/X11/fonts/fontconf.h])

commit 2351c83a77a478b49cba6beb2ad386835e264744
Author: Alan Coopersmith 
Date:   Fri Mar 6 22:54:58 2015 -0800

bdfReadCharacters: ensure metrics fit into xCharInfo struct [CVE-2015-1804]

We use 32-bit ints to read from the bdf file, but then try to stick
into a 16-bit int in the xCharInfo struct, so make sure they won't
overflow that range.

Found by afl-1.24b.

v2: Verify that additions won't overflow 32-bit int range either.
v3: As Julien correctly observes, the previous check for bh & bw not
being < 0 reduces the number of cases we need to check for overflow.

Signed-off-by: Alan Coopersmith 
Reviewed-by: Julien Cristau 

diff --git a/src/bitmap/bdfread.c b/src/bitmap/bdfread.c
index 1b29b81..a0ace8f 100644
--- a/src/bitmap/bdfread.c
+++ b/src/bitmap/bdfread.c
@@ -62,8 +62,16 @@ from The Open Group.
 
 #if HAVE_STDINT_H
 #include 
-#elif !defined(INT32_MAX)
-#define INT32_MAX 0x7fff
+#else
+# ifndef INT32_MAX
+#  define INT32_MAX 0x7fff
+# endif
+# ifndef INT16_MAX
+#  define INT16_MAX 0x7fff
+# endif
+# ifndef INT16_MIN
+#  define INT16_MIN (0 - 0x8000)
+# endif
 #endif
 
 #define INDICES 256
@@ -417,6 +425,12 @@ bdfReadCharacters(FontFilePtr file, FontPtr pFont, 
bdfFileState *pState,
bdfError("DWIDTH y value must be zero\n");
goto BAILOUT;
}
+   /* xCharInfo metrics are stored as INT16 */
+   if ((wx < 0) || (wx > INT16_MAX)) {
+   bdfError("character '%s' has out of range width, %d\n",
+charName, wx);
+   goto BAILOUT;
+   }
line = bdfGetLine(file, lineBuf, BDFLINELEN);
if ((!line) || (sscanf((char *) line, "BBX %d %d %d %d", &bw, &bh, &bl, 
&bb) != 4)) {
bdfError("bad 'BBX'\n");
@@ -427,6 +441,14 @@ bdfReadCharacters(FontFilePtr file, FontPtr pFont, 
bdfFileState *pState,
 charName, bw, bh);
goto BAILOUT;
}
+   /* xCharInfo metrics are read as int, but stored as INT16 */
+   if ((bl > INT16_MAX) || (bl < INT16_MIN) ||
+   (bb > INT16_MAX) || (bb < INT16_MIN) ||
+   (bw > (INT16_MAX - bl)) || (bh > (INT16_MAX - bb))) {
+   bdfError("character '%s' has out of range metrics, %d %d %d %d\n",
+charName, bl, (bl+bw), (bh+bb), -bb);
+   goto BAILOUT;
+   }
line = bdfGetLine(file, lineBuf, BDFLINELEN);
if ((line) && (bdfIsPrefix(line, "ATTRIBUTES"))) {
for (p = line + strlen("ATTRIBUTES ");

commit 78c2e3d70d29698244f70164428bd2868c0ab34c
Author: Alan Coopersmith 
Date:   Fri Feb 6 15:54:00 2015 -0800

bdfReadCharacters: bailout if a char's bitmap cannot be read [CVE-2015-1803]

Previously would charge on ahead with a NULL pointer in ci->bits, and
then crash later in FontCharInkMetrics() trying to access the bits.

Found with afl-1.23b.

Signed-off-by: Alan Coopersmith 
Reviewed-by: Julien Cristau 

diff --git a/src/bitmap/bdfread.c b/src/bitmap/bdfread.c
index 6387908..1b29b81 100644
--- a/src/bitmap/bdfread.c
+++ b/src/bitmap/bdfread.c
@@ -458,7 +458,10 @@ bdfReadCharacters(FontFilePtr file, FontPtr pFont, 
bdfFileState *pState,
ci->metrics.descent = -bb;
ci->metrics.characterWidth = wx;
ci->bits = NULL;
-   bdfReadBitmap(ci, file, bit, byte, glyph, scan, bitmapsSizes);
+   if (!bdfReadBitmap(ci, file, bit, byte, glyph, scan, bitmapsSizes)) 
{
+   bdfError("could not read bitmap for character '%s'\n", 
charName);
+   goto BAILOUT;
+   }
ci++;
ndx++;
} else

commit 2deda9906480f9c8ae07b8c2a5510cc7e4c59a8e
Author: Alan Coopersmith 
Date:   Fri Feb 6 15:50:45 2015 -0800

bdfReadProperties: property count needs range check [CVE-2015-1802]

Avoid integer overflow or underflow when allocating memory arrays
by multiplying the number of properties reported for a BDF font.

Reported-by: Ilja Van Sprundel 
Signed-off-by: Alan Coopersmith 
Reviewed-by: Julien Cristau 

diff --git a/s

libxfont: Changes to 'upstream-unstable'

2014-07-12 Thread Julien Cristau
 README   |   59 +
 configure.ac |   49 +--
 include/X11/fonts/fntfil.h   |   14 +-
 include/X11/fonts/fontmisc.h |2 
 src/FreeType/ftfuncs.c   |4 
 src/FreeType/xttcap.c|1 
 src/Makefile.am  |2 
 src/bitmap/Makefile.am   |   24 ++-
 src/bitmap/bitmap.c  |6 
 src/bitmap/bitmapfunc.c  |   31 ++--
 src/bitmap/bitscale.c|   26 
 src/builtins/builtin.h   |4 
 src/builtins/dir.c   |2 
 src/builtins/file.c  |2 
 src/builtins/fpe.c   |5 
 src/fc/fsconvert.c   |   18 ++
 src/fc/fserve.c  |  272 ++-
 src/fc/fserve.h  |2 
 src/fc/fsio.h|3 
 src/fontfile/bufio.c |6 
 src/fontfile/catalogue.c |   35 ++---
 src/fontfile/dirfile.c   |8 +
 src/fontfile/fontdir.c   |5 
 src/fontfile/fontfile.c  |   16 +-
 src/fontfile/renderers.c |6 
 src/stubs/Makefile.am|2 
 src/stubs/cauthgen.c |1 
 src/stubs/csignal.c  |1 
 src/stubs/delfntcid.c|1 
 src/stubs/errorf.c   |1 
 src/stubs/fatalerror.c   |   13 --
 src/stubs/findoldfnt.c   |1 
 src/stubs/getcres.c  |1 
 src/stubs/getdefptsize.c |1 
 src/stubs/getnewfntcid.c |1 
 src/stubs/gettime.c  |1 
 src/stubs/initfshdl.c|1 
 src/stubs/regfpefunc.c   |4 
 src/stubs/rmfshdl.c  |1 
 src/stubs/servclient.c   |9 +
 src/stubs/setfntauth.c   |1 
 src/stubs/stfntcfnt.c|1 
 src/stubs/stubs.h|   49 +++
 src/stubs/stubsinit.c|   82 
 src/util/atom.c  |4 
 src/util/miscutil.c  |   12 +
 src/util/patcache.c  |   14 +-
 47 files changed, 637 insertions(+), 167 deletions(-)

New commits:
commit b19cf2a78f7f721c43d0d9e2f32b71fc746142a3
Author: Alan Coopersmith 
Date:   Mon Jul 7 13:18:18 2014 -0700

libXfont 1.4.99.901

Signed-off-by: Alan Coopersmith 

diff --git a/configure.ac b/configure.ac
index 13fe3e1..d4320de 100644
--- a/configure.ac
+++ b/configure.ac
@@ -21,7 +21,7 @@
 
 # Initialize Autoconf
 AC_PREREQ([2.60])
-AC_INIT([libXfont], [1.4.99.0],
+AC_INIT([libXfont], [1.4.99.901],
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [libXfont])
 AC_CONFIG_SRCDIR([Makefile.am])
 AC_CONFIG_HEADERS([config.h include/X11/fonts/fontconf.h])

commit 0dcdd82059c69ec417bb094f4da2afef7cc1426a
Author: Yaakov Selkowitz 
Date:   Sun Apr 6 14:18:32 2014 -0500

Make shared library work on Cygwin/MinGW

Weak symbols on PE platforms do not work the same way as on ELF
platforms, hence we have been unable to have a fully functional shared
libXfont until now.  This patch works around these issues so that we
can fix that.

In summary, only when compiling shared libraries on NO_WEAK_SYMBOLS
platforms, when the first stub is called, the invoking program is first
checked to determine if it exports the stubbed functions.  Then, for
every stub call, if the function is exported by the loader, it is called
instead of the stub code.

serverClient and serverGeneration are data pointers, and therefore are
replaced by getter functions. ErrorF is variadic, so the override is
routed through VErrorF instead. FatalError has no va_list equivalent,
but it is not actually used in libXfont and therefore should be safe to
remove.

This requires all X servers to export their symbols, which requires
forthcoming patches for hw/xwin and xfs; the other xservers (including
tigervnc) already do this via LD_EXPORT_SYMBOLS_FLAG.

Signed-off-by: Yaakov Selkowitz 
Reviewed-by: Colin Harrison 
Acked-by: Alan Coopersmith 
Tested-by: Jeremy Huddleston Sequoia 

diff --git a/src/Makefile.am b/src/Makefile.am
index cd09ab9..33fd135 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -65,4 +65,4 @@ libXfont_la_LIBADD = \
 
 libXfont_la_SOURCES = dummy.c
 
-libXfont_la_LDFLAGS = -version-number 1:4:1
+libXfont_la_LDFLAGS = -version-number 1:4:1 -no-undefined
diff --git a/src/bitmap/bitscale.c b/src/bitmap/bitscale.c
index b32639f..c9af4c0 100644
--- a/src/bitmap/bitscale.c
+++ b/src/bitmap/bitscale.c
@@ -44,7 +44,7 @@ from The Open Group.
 #endif
 
 /* Should get this from elsewhere */
-extern unsigned long serverGeneration;
+extern unsigned long __GetServerGeneration(void);
 
 static void bitmapUnloadScalable (FontPtr pFont);
 static void ScaleBitmap ( FontPtr pFont, CharInfoPtr opci,
@@ -581,9 +581,9 @@ ComputeScaledProperties(FontInfoPtr sourceFontInfo, /* the 
font to be scaled */
 char   *isStringProp;
 intnProps;
 
-if (bitscaleGeneration != serverGeneration) {
+if (bitscaleGeneration != __GetServerGeneration()) {
initFontPropTable();

libxfont: Changes to 'upstream-unstable'

2014-01-07 Thread Julien Cristau
 configure.ac   |7 ++-
 src/FreeType/ftfuncs.c |   17 +
 src/FreeType/xttcap.c  |   23 +--
 src/FreeType/xttcap.h  |9 -
 src/bitmap/bdfread.c   |   16 
 src/fontfile/fontdir.c |   10 +++---
 src/util/atom.c|   20 
 src/util/miscutil.c|2 +-
 8 files changed, 44 insertions(+), 60 deletions(-)

New commits:
commit 30110063857ff9a5f93f6d8d13f535c9b6e59e2a
Author: Alan Coopersmith 
Date:   Tue Jan 7 08:22:31 2014 -0800

libXfont 1.4.7

Signed-off-by: Alan Coopersmith 

diff --git a/configure.ac b/configure.ac
index 3591a1a..01e7b6e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -21,7 +21,7 @@
 
 # Initialize Autoconf
 AC_PREREQ([2.60])
-AC_INIT([libXfont], [1.4.6],
+AC_INIT([libXfont], [1.4.7],
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [libXfont])
 AC_CONFIG_SRCDIR([Makefile.am])
 AC_CONFIG_HEADERS([config.h include/X11/fonts/fontconf.h])

commit 2a84680376bafd74609c6ef3e38befcb8467d814
Author: Alan Coopersmith 
Date:   Mon Dec 23 19:01:11 2013 -0800

Limit additional sscanf strings to fit buffer sizes

None of these could currently result in buffer overflow, as the input
and output buffers were the same size, but adding limits helps ensure
we keep it that way, if we ever resize any of these in the future.

Fixes cppcheck warnings:
 [lib/libXfont/src/bitmap/bdfread.c:547]: (warning)
  scanf without field width limits can crash with huge input data.
 [lib/libXfont/src/bitmap/bdfread.c:553]: (warning)
  scanf without field width limits can crash with huge input data.
 [lib/libXfont/src/bitmap/bdfread.c:636]: (warning)
  scanf without field width limits can crash with huge input data.

Signed-off-by: Alan Coopersmith 
Reviewed-by: Matthieu Herrb 
Reviewed-by: Jeremy Huddleston Sequoia 

diff --git a/src/bitmap/bdfread.c b/src/bitmap/bdfread.c
index e11c5d2..914a024 100644
--- a/src/bitmap/bdfread.c
+++ b/src/bitmap/bdfread.c
@@ -69,6 +69,7 @@ from The Open Group.
 #define INDICES 256
 #define MAXENCODING 0x
 #define BDFLINELEN  1024
+#define BDFLINESTR  "%1023s" /* scanf specifier to read a BDFLINELEN string */
 
 static Bool bdfPadToTerminal(FontPtr pFont);
 extern int  bdfFileLineNum;
@@ -544,13 +545,18 @@ bdfReadHeader(FontFilePtr file, bdfFileState *pState)
 unsigned charlineBuf[BDFLINELEN];
 
 line = bdfGetLine(file, lineBuf, BDFLINELEN);
-if (!line || sscanf((char *) line, "STARTFONT %s", namebuf) != 1 ||
+if (!line ||
+sscanf((char *) line, "STARTFONT " BDFLINESTR, namebuf) != 1 ||
!bdfStrEqual(namebuf, "2.1")) {
bdfError("bad 'STARTFONT'\n");
return (FALSE);
 }
 line = bdfGetLine(file, lineBuf, BDFLINELEN);
-if (!line || sscanf((char *) line, "FONT %[^\n]", pState->fontName) != 1) {
+#if MAXFONTNAMELEN != 1024
+# error "need to adjust sscanf length limit to be MAXFONTNAMELEN - 1"
+#endif
+if (!line ||
+sscanf((char *) line, "FONT %1023[^\n]", pState->fontName) != 1) {
bdfError("bad 'FONT'\n");
return (FALSE);
 }
@@ -633,7 +639,9 @@ bdfReadProperties(FontFilePtr file, FontPtr pFont, 
bdfFileState *pState)
while (*line && isspace(*line))
line++;
 
-   switch (sscanf((char *) line, "%s%s%s", namebuf, secondbuf, thirdbuf)) {
+   switch (sscanf((char *) line,
+   BDFLINESTR BDFLINESTR BDFLINESTR,
+   namebuf, secondbuf, thirdbuf)) {
default:
bdfError("missing '%s' parameter value\n", namebuf);
goto BAILOUT;

commit 4d024ac10f964f6bd372ae0dd14f02772a6e5f63
Author: Alan Coopersmith 
Date:   Mon Dec 23 18:34:02 2013 -0800

CVE-2013-6462: unlimited sscanf overflows stack buffer in 
bdfReadCharacters()

Fixes cppcheck warning:
 [lib/libXfont/src/bitmap/bdfread.c:341]: (warning)
  scanf without field width limits can crash with huge input data.

Signed-off-by: Alan Coopersmith 
Reviewed-by: Matthieu Herrb 
Reviewed-by: Jeremy Huddleston Sequoia 

diff --git a/src/bitmap/bdfread.c b/src/bitmap/bdfread.c
index e2770dc..e11c5d2 100644
--- a/src/bitmap/bdfread.c
+++ b/src/bitmap/bdfread.c
@@ -338,7 +338,7 @@ bdfReadCharacters(FontFilePtr file, FontPtr pFont, 
bdfFileState *pState,
charcharName[100];
int ignore;
 
-   if (sscanf((char *) line, "STARTCHAR %s", charName) != 1) {
+   if (sscanf((char *) line, "STARTCHAR %99s", charName) != 1) {
bdfError("bad character name in BDF file\n");
goto BAILOUT;   /* bottom of function, free and return error */
}

commit fdcf9a9be6a5d453659beadec5d1a1fdbab9afaf
Author: Alan Coopersmith 
Date:   Fri Dec 27 11:01:35 2013 -0800

Add AC_USE_SYSTEM_EXTENSIONS to expose non-standard extensions

Required on Solaris to expose definitions in sys

libxfont: Changes to 'upstream-unstable'

2013-08-12 Thread Julien Cristau
 autogen.sh   |4 +++-
 configure.ac |5 ++---
 src/FreeType/Makefile.am |6 +++---
 src/bitmap/Makefile.am   |2 +-
 src/builtins/Makefile.am |2 +-
 src/fc/Makefile.am   |2 +-
 src/fc/fservestr.h   |5 -
 src/fc/fsio.c|7 +--
 src/fontfile/Makefile.am |2 +-
 src/fontfile/bunzip2.c   |2 ++
 src/fontfile/catalogue.c |6 +-
 src/fontfile/register.c  |2 ++
 src/stubs/Makefile.am|2 +-
 src/util/Makefile.am |2 +-
 14 files changed, 28 insertions(+), 21 deletions(-)

New commits:
commit 8b289e10c5013cdcbf817c06bd929e3ea8339987
Author: Alan Coopersmith 
Date:   Sun Jul 21 16:53:47 2013 -0700

libXfont 1.4.6

Signed-off-by: Alan Coopersmith 

diff --git a/configure.ac b/configure.ac
index 338385f..e0e81bb 100644
--- a/configure.ac
+++ b/configure.ac
@@ -21,7 +21,7 @@
 
 # Initialize Autoconf
 AC_PREREQ([2.60])
-AC_INIT([libXfont], [1.4.5],
+AC_INIT([libXfont], [1.4.6],
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [libXfont])
 AC_CONFIG_SRCDIR([Makefile.am])
 AC_CONFIG_HEADERS([config.h include/X11/fonts/fontconf.h])

commit 7447029974415641a7a8a85918edcc20cfd9d461
Author: Alan Coopersmith 
Date:   Mon Jun 24 22:40:39 2013 -0700

Require ANSI C89 pre-processor, drop pre-C89 token pasting support

Signed-off-by: Alan Coopersmith 

diff --git a/src/fc/fservestr.h b/src/fc/fservestr.h
index 6435cf4..29ae46e 100644
--- a/src/fc/fservestr.h
+++ b/src/fc/fservestr.h
@@ -139,12 +139,7 @@ typedef struct _fs_reconnect {
 } FSReconnectRec, *FSReconnectPtr;
 
 
-#if !defined(UNIXCPP) || defined(ANSICPP)
 #define fsCat(x,y) x##_##y
-#else
-#define fsCat(x,y) x/**/_/**/y
-#endif
-
 
 /* copy XCharInfo parts of a protocol reply into a xCharInfo */
 

commit c21d25de05d82a761a3225b685e9adcb7bb374bd
Author: Thomas Klausner 
Date:   Sun Jun 2 21:03:27 2013 +0200

Protect config.h inclusion with ifdef HAVE_CONFIG_H, like usual.

Reviewed-by: Alan Coopersmith 
Signed-off-by: Alan Coopersmith 

diff --git a/src/fontfile/bunzip2.c b/src/fontfile/bunzip2.c
index 44d19f0..4078796 100644
--- a/src/fontfile/bunzip2.c
+++ b/src/fontfile/bunzip2.c
@@ -26,7 +26,9 @@
  */
 
 
+#ifdef HAVE_CONFIG_H
 #include "config.h"
+#endif
 
 #include 
 #include 

commit b8dd42dce868f9c16a59790ce51f0542b59cb79d
Author: Alan Coopersmith 
Date:   Tue Jan 15 18:30:32 2013 -0800

Replace deprecated Automake INCLUDES variable with AM_CPPFLAGS

Excerpt https://lists.gnu.org/archive/html/automake/2012-12/msg00038.html

  - Support for the long-deprecated INCLUDES variable will be removed
altogether in Automake 1.14.  The AM_CPPFLAGS variable should be
used instead.

This variable was deprecated in Automake releases prior to 1.10, which is
the current minimum level required to build X.

Signed-off-by: Alan Coopersmith 
Reviewed-by: Peter Hutterer 

diff --git a/src/FreeType/Makefile.am b/src/FreeType/Makefile.am
index fa45da1..ab60ffa 100644
--- a/src/FreeType/Makefile.am
+++ b/src/FreeType/Makefile.am
@@ -1,10 +1,10 @@
-INCLUDES =\
+AM_CPPFLAGS =  \
-I${top_srcdir}/include
 
-noinst_LTLIBRARIES = libft.la
-
 AM_CFLAGS = $(FREETYPE_CFLAGS) $(XFONT_CFLAGS) $(OS_CFLAGS) $(CWARNFLAGS)
 
+noinst_LTLIBRARIES = libft.la
+
 libft_la_SOURCES = \
ft.h\
ftfuncs.h   \
diff --git a/src/bitmap/Makefile.am b/src/bitmap/Makefile.am
index b5b9674..99682d9 100644
--- a/src/bitmap/Makefile.am
+++ b/src/bitmap/Makefile.am
@@ -1,4 +1,4 @@
-INCLUDES = \
+AM_CPPFLAGS =  \
-I${top_srcdir}/include
 
 AM_CFLAGS = $(XFONT_CFLAGS) $(OS_CFLAGS) $(CWARNFLAGS)
diff --git a/src/builtins/Makefile.am b/src/builtins/Makefile.am
index b203fda..6b96410 100644
--- a/src/builtins/Makefile.am
+++ b/src/builtins/Makefile.am
@@ -1,4 +1,4 @@
-INCLUDES = \
+AM_CPPFLAGS =  \
-I${top_srcdir}/include \
-I${top_srcdir}/src/bitmap
 
diff --git a/src/fc/Makefile.am b/src/fc/Makefile.am
index 3bfd231..c180cae 100644
--- a/src/fc/Makefile.am
+++ b/src/fc/Makefile.am
@@ -1,4 +1,4 @@
-INCLUDES =  \
+AM_CPPFLAGS =  \
-I${top_srcdir}/include
 
 AM_CFLAGS = $(XFONT_CFLAGS) $(OS_CFLAGS) $(CWARNFLAGS)
diff --git a/src/fontfile/Makefile.am b/src/fontfile/Makefile.am
index aa64ca5..ab54cfd 100644
--- a/src/fontfile/Makefile.am
+++ b/src/fontfile/Makefile.am
@@ -1,4 +1,4 @@
-INCLUDES = -I${top_srcdir}/include
+AM_CPPFLAGS = -I${top_srcdir}/include
 
 AM_CFLAGS = $(XFONT_CFLAGS) $(OS_CFLAGS) $(CWARNFLAGS)
 
diff --git a/src/stubs/Makefile.am b/src/stubs/Makefile.am
index 86dd8fc..23e3bd1 100644
--- a/src/stubs/Makefile.am
+++ b/src/stubs/Makefile.am
@@ -1,4 +1,4 @@
-INCLUDES = \
+AM_CPPFLAGS =  \
-I${

libxfont: Changes to 'upstream-unstable'

2012-03-04 Thread Cyril Brulebois
 Makefile.am  |6 
 configure.ac |   20 +-
 devbook.am   |   46 ++
 doc/fontlib.xml  |  114 +---
 include/X11/fonts/bdfint.h   |   16 +-
 include/X11/fonts/bitmap.h   |   18 +-
 include/X11/fonts/fntfil.h   |   94 ++---
 include/X11/fonts/fntfilst.h |   40 ++---
 include/X11/fonts/fontmisc.h |8 -
 include/X11/fonts/fontutil.h |   10 -
 include/X11/fonts/pcf.h  |4 
 src/FreeType/ftenc.c |   30 ++--
 src/FreeType/ftfuncs.c   |  278 
 src/FreeType/ftfuncs.h   |   10 -
 src/FreeType/fttools.c   |8 -
 src/FreeType/xttcap.c|   40 ++---
 src/FreeType/xttcap.h|4 
 src/Makefile.am  |6 
 src/bitmap/bdfread.c |   40 +++--
 src/bitmap/bdfutils.c|   21 +--
 src/bitmap/bitmap.c  |8 -
 src/bitmap/bitmapfunc.c  |   12 -
 src/bitmap/bitscale.c|  106 +++
 src/bitmap/fontink.c |2 
 src/bitmap/pcfread.c |   54 ---
 src/bitmap/pcfwrite.c|7 -
 src/bitmap/snfread.c |   18 +-
 src/bitmap/snfstr.h  |2 
 src/builtins/buildfont   |2 
 src/builtins/builtin.h   |4 
 src/builtins/dir.c   |4 
 src/builtins/file.c  |4 
 src/builtins/fonts.c |2 
 src/builtins/fpe.c   |2 
 src/builtins/render.c|2 
 src/fc/fsconvert.c   |   52 +++
 src/fc/fserve.c  |  296 +--
 src/fc/fservestr.h   |   18 +-
 src/fc/fsio.c|   26 +--
 src/fc/fsio.h|8 -
 src/fc/fslibos.h |2 
 src/fc/fstrans.c |2 
 src/fontfile/bitsource.c |   16 +-
 src/fontfile/bunzip2.c   |   12 -
 src/fontfile/catalogue.c |   34 ++--
 src/fontfile/decompress.c|   61 +++-
 src/fontfile/dirfile.c   |8 -
 src/fontfile/fontdir.c   |   16 +-
 src/fontfile/fontencc.c  |2 
 src/fontfile/fontfile.c  |   80 +--
 src/fontfile/fontscale.c |8 -
 src/fontfile/gunzip.c|   14 +-
 src/fontfile/register.c  |2 
 src/fontfile/renderers.c |4 
 src/stubs/Makefile.am|2 
 src/stubs/regfpefunc.c   |   30 ++--
 src/stubs/rmfshdl.c  |2 
 src/stubs/stubs.h|4 
 src/util/atom.c  |8 -
 src/util/fontaccel.c |4 
 src/util/fontutil.c  |   28 ++--
 src/util/fontxlfd.c  |   18 --
 src/util/format.c|   22 +--
 src/util/patcache.c  |   14 +-
 src/util/private.c   |4 
 src/util/utilbitmap.c|   22 +--
 66 files changed, 907 insertions(+), 954 deletions(-)

New commits:
commit 4b67ad5486c322c01a2ca86b0b4af0a74228f813
Author: Alan Coopersmith 
Date:   Fri Mar 2 10:05:21 2012 -0800

libXfont 1.4.5

Signed-off-by: Alan Coopersmith 

diff --git a/configure.ac b/configure.ac
index 8cff1d8..b274a8f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -21,7 +21,7 @@
 
 # Initialize Autoconf
 AC_PREREQ([2.60])
-AC_INIT([libXfont], [1.4.4],
+AC_INIT([libXfont], [1.4.5],
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [libXfont])
 AC_CONFIG_SRCDIR([Makefile.am])
 AC_CONFIG_HEADERS([config.h include/X11/fonts/fontconf.h])

commit 3f87a8b0b86de83ea8944a53de82caf254a9988a
Author: Alan Coopersmith 
Date:   Fri Oct 21 20:49:50 2011 -0700

Use * precision notation instead of computing sprintf format strings

Allows gcc to check format strings instead of just warning about them

Signed-off-by: Alan Coopersmith 
Reviewed-by: Jeremy Huddleston 

diff --git a/src/util/fontxlfd.c b/src/util/fontxlfd.c
index 18046e9..974128e 100644
--- a/src/util/fontxlfd.c
+++ b/src/util/fontxlfd.c
@@ -116,7 +116,6 @@ readreal(char *ptr, double *result)
 static char *
 xlfd_double_to_text(double value, char *buffer, int space_required)
 {
-char formatbuf[40];
 register char *p1;
 int ndigits, exponent;
 
@@ -132,14 +131,12 @@ xlfd_double_to_text(double value, char *buffer, int 
space_required)
minus = locale->negative_sign;
 }
 #endif
-/* Compute a format to use to render the number */
-sprintf(formatbuf, "%%.%dle", XLFD_NDIGITS);
 
 if (space_required)
*buffer++ = ' ';
 
 /* Render the number using printf's idea of formatting */
-sprintf(buffer, formatbuf, value);
+sprintf(buffer, "%.*le", XLFD_NDIGITS, value);
 
 /* Find and read the exponent value */
 for (p1 = buffer + strlen(buffer);
@@ -156,16 +153,14 @@ xlfd_double_to_text(double value, char *buffer, int 
space_required)
 if (exponent >= XLFD_NDIGITS || ndigits - exponent > XLFD_NDIGITS + 1)
 {
/* Scientific */
-   sprintf(formatbuf, "%%.%dle", ndigits - 1);
-   sprintf(buffer, formatbuf, value);
+   sprintf(buffer, "%.*le", ndigits - 1, value);

libxfont: Changes to 'upstream-unstable'

2011-08-11 Thread Cyril Brulebois
 COPYING   |2 
 configure.ac  |  110 +++---
 devbook.am|   61 +
 doc/.gitignore|2 
 doc/Makefile.am   |   62 +
 doc/fontlib.xml   |6 +-
 src/bitmap/bitscale.c |   11 +---
 src/fontfile/bunzip2.c|2 
 src/fontfile/decompress.c |2 
 9 files changed, 132 insertions(+), 126 deletions(-)

New commits:
commit a7970f5c817b5c75d945389cfaf1384ff23437f3
Author: Matthieu Herrb 
Date:   Mon Aug 8 18:08:05 2011 +0200

libXfont 1.4.4

Signed-off-by: Matthieu Herrb 
Signed-off-by: Alan Coopersmith 

diff --git a/configure.ac b/configure.ac
index c62d6e4..7aa7a1c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -27,7 +27,7 @@ AC_PREREQ([2.60])
 # Yes, it is a pain to synchronize version numbers.  Unfortunately, it's
 # not possible to extract the version number here from Xfont.h
 #
-AC_INIT([libXfont], [1.4.3],
+AC_INIT([libXfont], [1.4.4],
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [libXfont])
 AC_CONFIG_SRCDIR([Makefile.am])
 AC_CONFIG_HEADERS([config.h include/X11/fonts/fontconf.h])

commit d11ee5886e9d9ec610051a206b135a4cdc1e09a0
Author: Thomas Hoger 
Date:   Mon Aug 8 18:03:09 2011 +0200

LZW decompress: fix for CVE-2011-2895

Specially crafted LZW stream can crash an application using libXfont
that is used to open untrusted font files.  With X server, this may
allow privilege escalation when exploited

Reviewed-by: Matthieu Herrb 
Signed-off-by: Matthieu Herrb 
Signed-off-by: Alan Coopersmith 

diff --git a/src/fontfile/decompress.c b/src/fontfile/decompress.c
index b1fc37b..c8171dd 100644
--- a/src/fontfile/decompress.c
+++ b/src/fontfile/decompress.c
@@ -259,6 +259,8 @@ BufCompressedFill (BufFilePtr f)
 */
while ( code >= 256 )
{
+   if (stackp - de_stack >= STACK_SIZE - 1)
+   return BUFFILEEOF;
*stackp++ = file->tab_suffix[code];
code = file->tab_prefix[code];
}

commit 214ca6a7a2247544627e6dc7c8705811305ad007
Author: Alan Coopersmith 
Date:   Mon May 16 18:28:13 2011 -0700

Fix memory leak in allocation failure path of BitmapOpenScalable()

Go ahead and fill in the font->info pointers so that bitmapUnloadScalable()
will free the bits that were allocated, even if some were not.

Error: Memory leak (CWE 401)
   Memory leak of pointer  allocated with 
ComputeScaledProperties(...)
at line 1629 of 
/export/alanc/X.Org/git/lib/libXfont/src/bitmap/bitscale.c in function 
'BitmapOpenScalable'.
  pointer allocated at line 1616 with ComputeScaledProperties(...).
   leaks when props != 0 at line 1623.

[ This bug was found by the Parfait 0.3.7 bug checking tool.
  For more information see http://labs.oracle.com/projects/parfait/ ]

Signed-off-by: Alan Coopersmith 
Reviewed-by: Jeremy Huddleston 

diff --git a/src/bitmap/bitscale.c b/src/bitmap/bitscale.c
index cf16bff..50818c6 100644
--- a/src/bitmap/bitscale.c
+++ b/src/bitmap/bitscale.c
@@ -1620,19 +1620,16 @@ BitmapOpenScalable (FontPathElementPtr fpe,
 if (!sourceFont->refcnt)
FontFileCloseFont((FontPathElementPtr) 0, sourceFont);
 
+font->info.props = props;
+font->info.nprops = propCount;
+font->info.isStringProp = isStringProp;
+
 if (propCount && (!props || !isStringProp))
 {
-   font->info.nprops = 0;
-   font->info.props = (FontPropPtr)0;
-   font->info.isStringProp = (char *)0;
bitmapUnloadScalable(font);
return AllocError;
 }
 
-font->info.props = props;
-font->info.nprops = propCount;
-font->info.isStringProp = isStringProp;
-
 *pFont = font;
 return Successful;
 }

commit 7f8345aa6fb60a7fd7adf0095a2354fad1d8d5ef
Author: Gaetan Nadon 
Date:   Wed Mar 2 14:33:07 2011 -0500

doc: use common makefile for developers documentation

The user/specs docs now have external references support.
Developers doc are not installed so they do not participate.
However, using a similar makefile shared amongst developers
document reduces maintenance and is forward looking.

Signed-off-by: Gaetan Nadon 

diff --git a/configure.ac b/configure.ac
index 0dbb5a1..c62d6e4 100644
--- a/configure.ac
+++ b/configure.ac
@@ -45,9 +45,9 @@ m4_ifndef([XORG_MACROS_VERSION],
 XORG_MACROS_VERSION(1.10)
 XORG_DEFAULT_OPTIONS
 XORG_ENABLE_DEVEL_DOCS
-XORG_WITH_XMLTO(0.0.20)
+XORG_WITH_XMLTO(0.0.22)
 XORG_WITH_FOP
-XORG_CHECK_SGML_DOCTOOLS(1.5)
+XORG_CHECK_SGML_DOCTOOLS(1.7)
 
 # Checks for header files.
 AC_CHECK_HEADERS([endian.h poll.h sys/poll.h])
diff --git a/devbook.am b/devbook.am
new file mode 100644
index 000..62f4829
--- /dev/null
+++ b/devbook.am
@@ -0,0 +1,61 @@
+#
+# Generate output formats for a single DocBook/XML with/without chapters
+#
+# Varia

libxfont: Changes to 'upstream-unstable'

2010-11-06 Thread Cyril Brulebois
 .gitignore   |   74 ++-
 COPYING  |   71 -
 Makefile.am  |   33 ---
 configure.ac |   38 --
 doc/.gitignore   |6 +++
 doc/Makefile.am  |   66 ++
 doc/fontlib.css  |   46 --
 doc/fontlib.xml  |1 
 doc/fontlib.xsl  |   38 --
 include/X11/fonts/.gitignore |2 +
 include/X11/fonts/bdfint.h   |3 -
 include/X11/fonts/bitmap.h   |3 -
 include/X11/fonts/bufio.h|3 -
 include/X11/fonts/fntfil.h   |3 -
 include/X11/fonts/fntfilio.h |3 -
 include/X11/fonts/fntfilst.h |3 -
 include/X11/fonts/fontencc.h |1 
 include/X11/fonts/fontmisc.h |1 
 include/X11/fonts/fontshow.h |2 -
 include/X11/fonts/fontutil.h |2 -
 include/X11/fonts/fontxlfd.h |3 -
 include/X11/fonts/pcf.h  |3 -
 src/FreeType/ft.h|8 +---
 src/FreeType/ftenc.c |1 
 src/FreeType/ftfuncs.c   |   27 ---
 src/FreeType/ftfuncs.h   |1 
 src/FreeType/fttools.c   |2 -
 src/FreeType/xttcap.c|1 
 src/FreeType/xttcap.h|1 
 src/Makefile.am  |2 -
 src/bitmap/bdfread.c |3 -
 src/bitmap/bdfutils.c|2 -
 src/bitmap/bitmap.c  |3 -
 src/bitmap/bitmapfunc.c  |4 --
 src/bitmap/bitmaputil.c  |3 -
 src/bitmap/bitscale.c|1 
 src/bitmap/fontink.c |3 -
 src/bitmap/pcfread.c |1 
 src/bitmap/pcfwrite.c|2 -
 src/bitmap/snfread.c |2 -
 src/bitmap/snfstr.h  |2 -
 src/builtins/builtin.h   |2 -
 src/builtins/file.c  |3 -
 src/builtins/fonts.c |3 -
 src/builtins/fpe.c   |4 --
 src/builtins/render.c|4 --
 src/fc/fsconvert.c   |2 -
 src/fc/fserve.c  |3 -
 src/fc/fserve.h  |2 -
 src/fc/fservestr.h   |2 -
 src/fc/fsio.c|2 -
 src/fc/fsio.h|2 -
 src/fc/fslibos.h |2 -
 src/fontfile/bitsource.c |3 -
 src/fontfile/bufio.c |3 -
 src/fontfile/bunzip2.c   |   41 ++-
 src/fontfile/decompress.c|2 -
 src/fontfile/defaults.c  |3 -
 src/fontfile/dirfile.c   |3 -
 src/fontfile/fileio.c|3 -
 src/fontfile/filewr.c|3 -
 src/fontfile/fontdir.c   |4 --
 src/fontfile/fontencc.c  |1 
 src/fontfile/fontfile.c  |5 --
 src/fontfile/fontscale.c |3 -
 src/fontfile/gunzip.c|2 -
 src/fontfile/renderers.c |1 
 src/stubs/stubs.h|   16 +++--
 src/util/atom.c  |3 -
 src/util/fontaccel.c |3 -
 src/util/fontnames.c |4 --
 src/util/fontutil.c  |3 -
 src/util/fontxlfd.c  |3 -
 src/util/format.c|2 -
 src/util/miscutil.c  |   12 +-
 src/util/patcache.c  |3 -
 src/util/private.c   |3 -
 src/util/utilbitmap.c|1 
 xfont.pc.in  |2 -
 79 files changed, 229 insertions(+), 408 deletions(-)

New commits:
commit 12157fbebc35c2d039df2df4fc5ac2b299eeec03
Author: Alan Coopersmith 
Date:   Thu Oct 28 20:43:27 2010 -0700

libXfont 1.4.3

Signed-off-by: Alan Coopersmith 

diff --git a/configure.ac b/configure.ac
index 46fe9f7..8389dfc 100644
--- a/configure.ac
+++ b/configure.ac
@@ -23,7 +23,7 @@ dnl Process this file with autoconf to create configure.
 AC_PREREQ([2.60])
 
 AC_INIT([libXfont],
-   1.4.2,
+   [1.4.3],
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
libXfont)
 # Autoheader generates config.h.in. No new lines allowed in the list.

commit f29f1d68d7eca96e45ba3758686be07993d82e03
Author: Jesse Adkins 
Date:   Tue Sep 28 13:30:02 2010 -0700

Purge cvs tags.

Signed-off-by: Jesse Adkins 
Signed-off-by: Alan Coopersmith 

diff --git a/doc/fontlib.xml b/doc/fontlib.xml
index 8b7245e..f2e4811 100644
--- a/doc/fontlib.xml
+++ b/doc/fontlib.xml
@@ -6,7 +6,6 @@
 
   
 
-
 
 
 
diff --git a/include/X11/fonts/bdfint.h b/include/X11/fonts/bdfint.h
index d41c4a5..913f660 100644
--- a/include/X11/fonts/bdfint.h
+++ b/include/X11/fonts/bdfint.h
@@ -1,5 +1,3 @@
-/* $Xorg: bdfint.h,v 1.4 2001/02/09 02:04:01 xorgcvs Exp $ */
-
 /*
 
 Copyright 1990, 1998  The Open Group
@@ -27,7 +25,6 @@ other dealings in this Software without prior written 
authorization
 from The Open Group.
 
 */
-/* $XFree86: xc/lib/font/bitmap/bdfint.h,v 1.4 2001/01/17 19:43:26 dawes Exp $ 
*/
 
 #ifndef BDFINT_H
 #define BDFINT_H
diff --git a/include/X11/fonts/bitmap.h b/include/X11/fonts/bitmap.h
index 9b170a9..c023427 100644
--- a/include/X11/fon

libxfont: Changes to 'upstream-unstable'

2009-12-01 Thread Julien Cristau
 .gitignore   |4 
 Makefile.am  |   21 +
 configure.ac |   32 +-
 doc/fontlib.css  |   46 +++
 doc/fontlib.xml  |  660 +++
 doc/fontlib.xsl  |   38 ++
 src/Makefile.am  |2 
 src/fontfile/Makefile.am |7 
 src/fontfile/fontdir.c   |3 
 9 files changed, 790 insertions(+), 23 deletions(-)

New commits:
commit 64f21944c5f374b0da63657f01e289b34d00904c
Author: Alan Coopersmith 
Date:   Fri Oct 9 17:38:33 2009 -0700

libXfont 1.4.1

Signed-off-by: Alan Coopersmith 

diff --git a/configure.ac b/configure.ac
index c98a5ef..399f7d0 100644
--- a/configure.ac
+++ b/configure.ac
@@ -23,7 +23,7 @@ dnl Process this file with autoconf to create configure.
 AC_PREREQ([2.57])
 
 AC_INIT([libXfont],
-   1.4.0,
+   1.4.1,
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
libXfont)
 dnl

commit 947d3162f5edaaa05bbbfcfe2303d0c8b796f9ca
Author: Alan Coopersmith 
Date:   Wed Oct 7 13:05:26 2009 -0700

Remove unused setting of ENCODINGSDIR

Seems to have been a leftover from before the encoding code was split
out into libfontenc by XFree86

Signed-off-by: Alan Coopersmith 

diff --git a/configure.ac b/configure.ac
index 5c0a4a5..c98a5ef 100644
--- a/configure.ac
+++ b/configure.ac
@@ -67,13 +67,6 @@ AC_CHECK_FUNCS([poll])
 
 m4_ifdef([AS_HELP_STRING], , [m4_define([AS_HELP_STRING], 
m4_defn([AC_HELP_STRING]))])
 
-DEFAULT_ENCODINGSDIR=${libdir}/X11/fonts/encodings
-AC_ARG_WITH(encodingsdir,
-   AS_HELP_STRING([--with-encodingsdir=ENCODINGSDIR], [Path to font 
encodings]),
-   [ENCODINGSDIR="$withval"],
-   [ENCODINGSDIR="$DEFAULT_ENCODINGSDIR"])
-AC_SUBST(ENCODINGSDIR)
-
 #
 # select libraries to include
 #
diff --git a/src/fontfile/Makefile.am b/src/fontfile/Makefile.am
index 05aded2..aa64ca5 100644
--- a/src/fontfile/Makefile.am
+++ b/src/fontfile/Makefile.am
@@ -1,9 +1,4 @@
-fontencd...@encodingsdir@
-FONTENCDEFS = -DFONT_ENCODINGS_DIRECTORY=\"$(FONTENCDIR)/encodings.dir\"
-
-INCLUDES = \
-   -I${top_srcdir}/include \
-   $(FONTENCDEFS)  
+INCLUDES = -I${top_srcdir}/include
 
 AM_CFLAGS = $(XFONT_CFLAGS) $(OS_CFLAGS) $(CWARNFLAGS)
 

commit 18053ffbf92473ffce23a3c5182de92b608b9cdf
Author: Alan Coopersmith 
Date:   Wed Oct 7 10:44:27 2009 -0700

Convert documentation from troff to DocBook/XML

Signed-off-by: Alan Coopersmith 

diff --git a/.gitignore b/.gitignore
index 70042c5..e0351c9 100644
--- a/.gitignore
+++ b/.gitignore
@@ -28,3 +28,7 @@ xfont.pc
 libXfont-*.tar.*
 ChangeLog
 tags
+doc/fontlib.txt
+doc/fontlib.html
+doc/fontlib.ps
+doc/fontlib.pdf
diff --git a/Makefile.am b/Makefile.am
index 1da055b..b90a7ad 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -52,3 +52,24 @@ ChangeLog:
 
 dist-hook: ChangeLog
 
+# Developer documentation - not installed on system
+EXTRA_DIST += doc/fontlib.xml doc/fontlib.xsl doc/fontlib.css
+
+if MAKE_DEVEL_DOCS
+if HAVE_XMLTO
+noinst_DATA = doc/fontlib.txt doc/fontlib.html $(srcdir)/doc/fontlib.css
+CLEANFILES = doc/fontlib.txt doc/fontlib.html doc/fontlib.pdf doc/fontlib.ps
+
+doc/fontlib.txt: $(srcdir)/doc/fontlib.xml $(srcdir)/doc/fontlib.xsl
+   $(AM_V_GEN)$(XMLTO) -m $(srcdir)/doc/fontlib.xsl -o doc txt 
$(srcdir)/doc/fontlib.xml
+
+doc/fontlib.html: $(srcdir)/doc/fontlib.xml $(srcdir)/doc/fontlib.xsl
+   $(AM_V_GEN)$(XMLTO) -m $(srcdir)/doc/fontlib.xsl -o doc xhtml-nochunks 
$(srcdir)/doc/fontlib.xml
+
+doc/fontlib.pdf: $(srcdir)/doc/fontlib.xml $(srcdir)/doc/fontlib.xsl
+   $(AM_V_GEN)$(XMLTO) -m $(srcdir)/doc/fontlib.xsl -o doc pdf 
$(srcdir)/doc/fontlib.xml
+
+doc/fontlib.ps: $(srcdir)/doc/fontlib.xml $(srcdir)/doc/fontlib.xsl
+   $(AM_V_GEN)$(XMLTO) -m $(srcdir)/doc/fontlib.xsl -o doc ps 
$(srcdir)/doc/fontlib.xml
+endif HAVE_XMLTO
+endif MAKE_DEVEL_DOCS
diff --git a/configure.ac b/configure.ac
index bd096f4..5c0a4a5 100644
--- a/configure.ac
+++ b/configure.ac
@@ -49,6 +49,18 @@ PKG_PROG_PKG_CONFIG
 
 XORG_DEFAULT_OPTIONS
 
+# xmlto is used to convert doc/fontlib.xml from DocBook to PDF/HTML
+AC_ARG_VAR([XMLTO], [Path to xmlto command])
+AC_PATH_PROG([XMLTO], [xmlto])
+AM_CONDITIONAL([HAVE_XMLTO], [test "x$XMLTO" != "x"])
+
+# Option to enable support for building developer internals docs
+AC_ARG_ENABLE(devel-docs,
+   AS_HELP_STRING([--enable-devel-docs],
+   [Build internals documentation for developers (default: enabled)]),
+   [DEVEL_DOCS=$enableval], [DEVEL_DOCS=yes])
+AM_CONDITIONAL([MAKE_DEVEL_DOCS], [test "x$DEVEL_DOCS" = "xyes"])
+
 # Look for headers
 AC_CHECK_HEADERS([endian.h poll.h sys/poll.h])
 AC_CHECK_FUNCS([poll])
diff --git a/doc/fontlib.css b/doc/fontlib.css
new file mode 100644
index 000..137200f
--- /dev/null
+++ b/doc/fontlib.css
@@ -0,0 +1,46 @@
+/* Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
+ *
+ * Permission is hereby granted, free of charge, to any p

libxfont: Changes to 'upstream-unstable'

2009-04-13 Thread Julien Cristau
 .gitignore  |   11 
 Makefile.am |3 
 configure.ac|   27 
 include/X11/fonts/.gitignore|2 
 include/X11/fonts/bitmap.h  |5 
 include/X11/fonts/bufio.h   |7 
 include/X11/fonts/fntfilst.h|2 
 include/X11/fonts/fontconf.h.in |6 
 include/X11/fonts/fontmisc.h|   32 
 include/X11/fonts/fontmod.h |   16 
 include/X11/fonts/pcf.h |2 
 src/.gitignore  |6 
 src/FreeType/.gitignore |6 
 src/FreeType/ft.h   |4 
 src/FreeType/ftenc.c|6 
 src/FreeType/ftfuncs.c  |  133 +-
 src/FreeType/fttools.c  |6 
 src/FreeType/xttcap.c   |   43 
 src/FreeType/xttcap.h   |4 
 src/Makefile.am |   16 
 src/Speedo/.gitignore   |6 
 src/Speedo/Makefile.am  |   34 
 src/Speedo/adobe-iso.h  |  200 
 src/Speedo/bics-iso.h   |  224 
 src/Speedo/bics-unicode.c   |  138 ---
 src/Speedo/bics-unicode.h   |3 
 src/Speedo/do_char.c|  809 --
 src/Speedo/do_trns.c|  498 ---
 src/Speedo/keys.h   |   56 -
 src/Speedo/out_bl2d.c   |  772 -
 src/Speedo/out_blk.c|  706 ---
 src/Speedo/out_outl.c   |  290 --
 src/Speedo/out_scrn.c   | 1090 
 src/Speedo/out_util.c   |  339 ---
 src/Speedo/reset.c  |  129 --
 src/Speedo/set_spcs.c   |  763 
 src/Speedo/set_trns.c   | 1214 ---
 src/Speedo/spdo_prv.h   |  262 -
 src/Speedo/speedo.h |  874 ---
 src/Speedo/spencode.c   |   67 -
 src/Speedo/sperr.c  |  127 --
 src/Speedo/spfile.c |  460 --
 src/Speedo/spfont.c |  453 --
 src/Speedo/spfuncs.c|  167 ---
 src/Speedo/spglyph.c|  399 
 src/Speedo/spinfo.c |  462 --
 src/Speedo/spint.h  |  178 ---
 src/Speedo/useropt.h|   41 
 src/Type1/.gitignore|6 
 src/Type1/Makefile.am   |   52 -
 src/Type1/arith.c   |  212 
 src/Type1/arith.h   |   71 -
 src/Type1/blues.h   |   95 --
 src/Type1/cluts.h   |   35 
 src/Type1/curves.c  |  228 -
 src/Type1/curves.h  |   44 
 src/Type1/digit.h   |   64 -
 src/Type1/fontfcn.c |  317 ---
 src/Type1/fontfcn.h |  114 --
 src/Type1/fonts.h   |   49 -
 src/Type1/hdigit.h  |   94 --
 src/Type1/hints.c   |  890 ---
 src/Type1/hints.h   |   48 -
 src/Type1/lines.c   |  188 
 src/Type1/lines.h   |   37 
 src/Type1/objects.c |  944 -
 src/Type1/objects.h |  293 --
 src/Type1/paths.c   |  748 
 src/Type1/paths.h   |  205 
 src/Type1/pictures.h|   50 -
 src/Type1/regions.c | 1328 -
 src/Type1/regions.h |  224 
 src/Type1/scanfont.c| 1526 -
 src/Type1/spaces.c  |  941 
 src/Type1/spaces.h  |  151 ---
 src/Type1/strokes.h |   38 
 src/Type1/t1funcs.c |  754 
 src/Type1/t1hdigit.h|   40 
 src/Type1/t1imager.h|   84 -
 src/Type1/t1info.c  |  496 ---
 src/Type1/t1intf.h  |   54 -
 src/Type1/t1io.c|  299 --
 src/Type1/t1malloc.c|  759 
 src/Type1/t1snap.c  |   85 -
 src/Type1/t1stdio.h |   94 --
 src/Type1/t1unicode.c   |  251 -
 src/Type1/t1unicode.h   |   25 
 src/Type1/token.c   | 1208 --
 src/Type1/token.h   |   79 -
 src/Type1/tokst.h   |  510 ---
 src/Type1/trig.h|   41 
 src/Type1/type1.c   | 1797 
 src/Type1/util.c|  194 
 src/Type1/util.h|  190 
 src/bitmap/.gitignore   |6 
 src/bitmap/bdfread.c|   71 -
 src/bitmap/bdfutils.c   |8 
 src/bitmap/bitmapfunc.c |   13 
 src/bitmap/bitmaputil.c |2 
 src/bitmap/bitscale.c   |  369 
 src/bitmap/pcfread.c|  327 ---
 src/bitmap/pcfwrite.c   |6 
 src/bitmap/snfread.c|   62 -
 src/builtins/.gitignore |6 
 src/builtins/dir.c  |   19 
 src/builtins/file.c |6 
 src/builtins/render.c   |4 
 src/fc/.gitignore   | 

libxfont: Changes to 'upstream-unstable'

2009-02-16 Thread Julien Cristau
 COPYING   |   54 ++
 Makefile.am   |5 
 README|   25 +
 configure.ac  |   49 --
 include/X11/fonts/bufio.h |3 
 src/FreeType/Makefile.am  |2 
 src/Makefile.am   |   11 
 src/Speedo/Makefile.am|2 
 src/Type1/Makefile.am |2 
 src/bitmap/Makefile.am|2 
 src/bitmap/bitmapfunc.c   |   51 +-
 src/bitmap/bitscale.c |   21 
 src/builtins/Makefile.am  |2 
 src/builtins/dir.c|6 
 src/fc/Makefile.am|2 
 src/fc/fserve.c   |   10 
 src/fc/fsio.c |2 
 src/fontcache/.gitignore  |6 
 src/fontcache/Makefile.am |8 
 src/fontcache/fcqueue.h   |  133 -
 src/fontcache/fontcache.c | 1022 --
 src/fontcache/fontcache.h |  121 -
 src/fontfile/Makefile.am  |6 
 src/fontfile/bunzip2.c|  179 
 src/fontfile/catalogue.c  |   14 
 src/fontfile/ffcheck.c|2 
 src/fontfile/fileio.c |9 
 src/fontfile/fontdir.c|2 
 src/fontfile/register.c   |2 
 src/stubs/Makefile.am |2 
 src/util/Makefile.am  |2 
 src/util/miscutil.c   |2 
 32 files changed, 395 insertions(+), 1364 deletions(-)

New commits:
commit 282ac4226195d58e3818e7ac97093e396aa78086
Author: Alan Coopersmith 
Date:   Fri Dec 19 15:07:21 2008 -0800

Version bump: 1.3.4

diff --git a/configure.ac b/configure.ac
index f199743..4a6c1e0 100644
--- a/configure.ac
+++ b/configure.ac
@@ -23,7 +23,7 @@ dnl Process this file with autoconf to create configure.
 AC_PREREQ([2.57])
 
 AC_INIT([libXfont],
-   1.3.3,
+   1.3.4,
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
libXfont)
 dnl

commit 5c631ad798fcdea4f2b7d0b012ac94182fad4184
Author: Alan Coopersmith 
Date:   Fri Dec 19 14:01:28 2008 -0800

miscutil.c:108: warning: old-style parameter declaration

diff --git a/src/util/miscutil.c b/src/util/miscutil.c
index 43473b7..c44527a 100644
--- a/src/util/miscutil.c
+++ b/src/util/miscutil.c
@@ -104,6 +104,6 @@ CopyISOLatin1Lowered (char *dst, char *src, int len)
 }
 
 weak void
-register_fpe_functions ()
+register_fpe_functions (void)
 {
 }

commit d21d6c5b23a23f120f32b483ec6b86cf88cb3a98
Author: Alan Coopersmith 
Date:   Fri Dec 19 13:47:48 2008 -0800

Add simple README with pointers to bugzilla/git/mailing list

diff --git a/README b/README
new file mode 100644
index 000..97a9e8a
--- /dev/null
+++ b/README
@@ -0,0 +1,25 @@
+libXfont provides the core of the legacy X11 font system, handling the
+index files (fonts.dir, fonts.alias, fonts.scale), the various font file
+formats, and rasterizing them.   It is used by the X servers, the
+X Font Server (xfs), and some font utilities (bdftopcf for instance),
+but should not be used by normal X11 clients.  X11 clients access fonts
+via either the new API's in libXft, or the legacy API's in libX11.
+
+Please submit bugs & patches to the Xorg bugzilla:
+
+   https://bugs.freedesktop.org/enter_bug.cgi?product=xorg
+
+All questions regarding this software should be directed at the
+Xorg mailing list:
+
+   http://lists.freedesktop.org/mailman/listinfo/xorg
+
+The master development code repository can be found at:
+
+   git://anongit.freedesktop.org/git/xorg/lib/libXfont
+
+   http://cgit.freedesktop.org/xorg/lib/libXfont
+
+For more information on the git code manager, see:
+
+   http://wiki.x.org/wiki/GitPage

commit d3be1261d29b7d8eda124add3497a93ebe34712c
Author: Alan Coopersmith 
Date:   Fri Dec 19 13:47:27 2008 -0800

Update COPYING file with additional copyrights/licenses

diff --git a/COPYING b/COPYING
index 1cd3635..dc48a0f 100644
--- a/COPYING
+++ b/COPYING
@@ -1,5 +1,10 @@
 Copyright (c) 1997 by Mark Leisher
 Copyright (c) 1998-2003 by Juliusz Chroboczek
+Copyright (c) 1998 Go Watanabe, All rights reserved.
+Copyright (c) 1998 Kazushi (Jam) Marukawa, All rights reserved.
+Copyright (c) 1998 Takuya SHIOZAKI, All rights reserved.
+Copyright (c) 1998 X-TrueType Server Project, All rights reserved.
+Copyright (c) 2003-2004 After X-TT Project, All rights reserved.
 
 Permission is hereby granted, free of charge, to any person obtaining a copy
 of this software and associated documentation files (the "Software"), to deal
@@ -233,3 +238,52 @@ Except as contained in this notice, the name of The 
XFree86 Project
 Inc. shall not be used in advertising or otherwise to promote the
 sale, use or other dealings in this Software without prior written
 authorization from The XFree86 Project Inc..
+
+Copyright � 2007 Red Hat, Inc
+
+Permission is hereby granted, free of charge, to any person obtaining a
+copy of this software and associated documentation files (the "Software"),
+to deal in the Software without restriction, including without limitation
+the rights to use, copy, modify, merge, publish, distribute, sublicense,
+and/or sell copies of the Software, and to permit persons to whom the
+Software is 

libxfont: Changes to 'upstream-unstable'

2008-07-17 Thread Julien Cristau
 Makefile.am |2 --
 configure.ac|2 +-
 include/X11/fonts/fontconf.h.in |2 --
 src/FreeType/ftenc.c|4 
 src/FreeType/ftfuncs.c  |1 +
 src/Makefile.am |2 --
 src/fc/fstrans.c|2 --
 src/fontfile/dirfile.c  |6 ++
 src/fontfile/fontdir.c  |4 
 9 files changed, 16 insertions(+), 9 deletions(-)

New commits:
commit 684c000e57f30344777cf763f2f1b540ef008b38
Author: Adam Jackson <[EMAIL PROTECTED]>
Date:   Wed Jul 2 15:30:03 2008 -0400

libXfont 1.3.3

diff --git a/configure.ac b/configure.ac
index 7d7ba75..fe55e41 100644
--- a/configure.ac
+++ b/configure.ac
@@ -23,7 +23,7 @@ dnl Process this file with autoconf to create configure.
 AC_PREREQ([2.57])
 
 AC_INIT([libXfont],
-   1.3.2,
+   1.3.3,
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
libXfont)
 dnl

commit 11edbc3a818e15ea2b622b31e6f87159ee68ae4a
Author: Maarten ter Huurne <[EMAIL PROTECTED]>
Date:   Sat Jun 28 15:34:50 2008 -0400

Do not call FT_Get_BDF_Charset_ID() if configured with --disable-bdfformat

When I configure libXfont-1.3.2 with --disable-bdfformat and link it against
FreeType that is built without BDF support, I get the following link error:

libXfont.so: undefined reference to ‘FT_Get_BDF_Charset_ID’

I fixed it by checking XFONT_BDFFORMAT and if BDF support is disabled, the 
call
to FT_Get_BDF_Charset_ID() is omitted and the result code is set as if the 
call
had failed.

Signed-off-by: James Cloos <[EMAIL PROTECTED]>

diff --git a/src/FreeType/ftenc.c b/src/FreeType/ftenc.c
index a9d6494..f6436fc 100644
--- a/src/FreeType/ftenc.c
+++ b/src/FreeType/ftenc.c
@@ -86,7 +86,11 @@ FTPickMapping(char *xlfd, int length, char *filename, 
FT_Face face,
 
 symbol = FTEncFontSpecific(encoding_name);
 
+#if XFONT_BDFFORMAT
 ftrc = FT_Get_BDF_Charset_ID(face, &enc, ®);
+#else
+ftrc = -1;
+#endif
 if(ftrc == 0) {
 /* Disable reencoding for non-Unicode fonts.  This will
currently only work for BDFs. */

commit 1ab07ce0eec4f6c7ed66c7aba3edf8c4315dd907
Author: Alan Coopersmith <[EMAIL PROTECTED]>
Date:   Tue May 13 17:26:57 2008 -0700

FontFileDirectoryChanged: check length of "fonts.alias" as well as 
"fonts.dir"

diff --git a/src/fontfile/dirfile.c b/src/fontfile/dirfile.c
index a13798a..1489938 100755
--- a/src/fontfile/dirfile.c
+++ b/src/fontfile/dirfile.c
@@ -176,6 +176,9 @@ FontFileDirectoryChanged(FontDirectoryPtr dir)
 }
 if (dir->dir_mtime != statb.st_mtime)
return TRUE;
+
+if ((strlen(dir->directory) + sizeof(FontAliasFile)) > sizeof(dir_file))
+   return FALSE;
 strcpy (dir_file, dir->directory);
 strcat (dir_file, FontAliasFile);
 if (stat (dir_file, &statb) == -1)

commit 0f9db4aa7de6e0644ac9c5811b949e5f936c9d61
Author: Alan Coopersmith <[EMAIL PROTECTED]>
Date:   Fri May 9 12:36:30 2008 -0700

Don't allow a font alias to point to itself and create a loop

Part of fix for Sun bug 4258475


diff --git a/src/fontfile/fontdir.c b/src/fontfile/fontdir.c
index cf68a54..cd9fde1 100644
--- a/src/fontfile/fontdir.c
+++ b/src/fontfile/fontdir.c
@@ -811,6 +811,10 @@ FontFileAddFontAlias (FontDirectoryPtr dir, char 
*aliasName, char *fontName)
 {
 FontEntryRec   entry;
 
+if (strcmp(aliasName,fontName) == 0) {
+/* Don't allow an alias to point to itself and create a loop */
+return FALSE;
+}
 entry.name.length = strlen (aliasName);
 CopyISOLatin1Lowered (aliasName, aliasName, entry.name.length);
 entry.name.name = aliasName;

commit 67311922a2e02d8a763831831b65bb4833db58b5
Author: Colin Harrison 
Date:   Mon May 5 22:17:55 2008 +0100

Fix build for WIN32

diff --git a/src/fontfile/dirfile.c b/src/fontfile/dirfile.c
old mode 100644
new mode 100755
index 3159a5e..a13798a
--- a/src/fontfile/dirfile.c
+++ b/src/fontfile/dirfile.c
@@ -66,6 +66,9 @@ FontFileReadDirectory (char *directory, FontDirectoryPtr 
*pdir)
 status;
 struct statstatb;
 static char format[24] = "";
+#if defined(__UNIXOS2__) || defined(WIN32)
+int i;
+#endif
 
 FontDirectoryPtr   dir = NullFontDirectory;
 

commit 6ba408c956ca8e241d10d463c45b4e987b757333
Author: Matthieu Herrb <[EMAIL PROTECTED]>
Date:   Sun Mar 9 08:21:34 2008 +0100

nuke RCS Ids

diff --git a/Makefile.am b/Makefile.am
index 8b354d7..f5e9c4e 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,6 +1,4 @@
 # 
-#  $Id$
-# 
 #  Copyright © 2003 Keith Packard, Noah Levitt
 # 
 #  Permission to use, copy, modify, distribute, and sell this software and its
diff --git a/include/X11/fonts/fontconf.h.in b/include/X11/fonts/fontconf.h.in
index b16df93..f12081d 100644
--- a/include/X11/fonts/fontconf.h.in
+++ b/include/X11/fonts/fontconf.h.in
@@ -1,6 +

libxfont: Changes to 'upstream-unstable'

2008-03-07 Thread Julien Cristau
 configure.ac |5 
 src/FreeType/Makefile.am |2 
 src/FreeType/ftsystem.c  |  331 ---
 src/bitmap/pcfread.c |6 
 src/builtins/dir.c   |   18 +-
 src/builtins/file.c  |3 
 src/fontfile/catalogue.c |2 
 7 files changed, 19 insertions(+), 348 deletions(-)

New commits:
commit 0fd2a1428df56d8b29e148b08dcec2dfed9302fa
Author: Adam Jackson <[EMAIL PROTECTED]>
Date:   Wed Mar 5 22:04:06 2008 -0500

libXfont 1.3.2

diff --git a/configure.ac b/configure.ac
index 63737ad..7d7ba75 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,6 +1,3 @@
-dnl 
-dnl  $Id$
-dnl 
 dnl  Copyright © 2003 Keith Packard
 dnl 
 dnl  Permission to use, copy, modify, distribute, and sell this software and 
its
@@ -26,7 +23,7 @@ dnl Process this file with autoconf to create configure.
 AC_PREREQ([2.57])
 
 AC_INIT([libXfont],
-   1.3.1,
+   1.3.2,
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
libXfont)
 dnl

commit b76df66d2c507898472bba0f9986ef5700029a36
Author: Matthieu Herrb <[EMAIL PROTECTED]>
Date:   Thu Jan 17 15:30:37 2008 +0100

Fix for CVE-2008-0006 - PCF Font parser buffer overflow.

diff --git a/src/bitmap/pcfread.c b/src/bitmap/pcfread.c
index fd41849..c5db255 100644
--- a/src/bitmap/pcfread.c
+++ b/src/bitmap/pcfread.c
@@ -588,6 +588,9 @@ pcfReadFont(FontPtr pFont, FontFilePtr file,
 pFont->info.lastRow = pcfGetINT16(file, format);
 pFont->info.defaultCh = pcfGetINT16(file, format);
 if (IS_EOF(file)) goto Bail;
+if (pFont->info.firstCol > pFont->info.lastCol ||
+   pFont->info.firstRow > pFont->info.lastRow ||
+   pFont->info.lastCol-pFont->info.firstCol > 255) goto Bail;
 
 nencoding = (pFont->info.lastCol - pFont->info.firstCol + 1) *
(pFont->info.lastRow - pFont->info.firstRow + 1);
@@ -726,6 +729,9 @@ pcfReadFontInfo(FontInfoPtr pFontInfo, FontFilePtr file)
 pFontInfo->lastRow = pcfGetINT16(file, format);
 pFontInfo->defaultCh = pcfGetINT16(file, format);
 if (IS_EOF(file)) goto Bail;
+if (pFontInfo->firstCol > pFontInfo->lastCol ||
+   pFontInfo->firstRow > pFontInfo->lastRow ||
+   pFontInfo->lastCol-pFontInfo->firstCol > 255) goto Bail;
 
 nencoding = (pFontInfo->lastCol - pFontInfo->firstCol + 1) *
(pFontInfo->lastRow - pFontInfo->firstRow + 1);

commit 2297c6390a1609fe810c2cd5b3443f3722610944
Author: Matthieu Herrb <[EMAIL PROTECTED]>
Date:   Thu Oct 18 21:46:49 2007 +0200

ftsystem.c is not needed anymore.

diff --git a/src/FreeType/Makefile.am b/src/FreeType/Makefile.am
index a138314..8e67837 100644
--- a/src/FreeType/Makefile.am
+++ b/src/FreeType/Makefile.am
@@ -13,5 +13,3 @@ libft_la_SOURCES =\
ftfuncs.c   \
fttools.c   \
xttcap.c
-
-EXTRA_DIST = ftsystem.c
diff --git a/src/FreeType/ftsystem.c b/src/FreeType/ftsystem.c
deleted file mode 100644
index ae5aa00..000
--- a/src/FreeType/ftsystem.c
+++ /dev/null
@@ -1,331 +0,0 @@
-/***/
-/* */
-/*  ftsystem.c */
-/* */
-/*ANSI-specific FreeType low-level system interface (body).*/
-/* */
-/*  Copyright 1996-2001, 2002 by   */
-/*  David Turner, Robert Wilhelm, and Werner Lemberg.  */
-/* */
-/*  Modified for XFree86.  */
-/* */
-/*  This file is part of the FreeType project, and may only be used,   */
-/*  modified, and distributed under the terms of the FreeType project  */
-/*  license, LICENSE.TXT.  By continuing to use, modify, or distribute */
-/*  this file you indicate that you have read the license and  */
-/*  understand and accept it fully.*/
-/* */
-/***/
-
-/* Modified for XFree86 */
-/* $XFree86$ */
-
-  /*/
-  /*   */
-  /* This file contains the default interface used by FreeType to access   */
-  /* low-level, i.e. memory management, i/o access as well as thread   */
-  /* synchronisation.  It can be replaced by user-specific routines if */
-  /* necessary.*/
-  /*

libxfont: Changes to 'upstream-unstable'

2007-09-05 Thread Julien Cristau
 configure.ac |2 
 src/FreeType/fttools.c   |7 --
 src/builtins/dir.c   |  155 +++
 src/fontfile/catalogue.c |   23 ++
 4 files changed, 177 insertions(+), 10 deletions(-)

New commits:
commit f2725a5c9da771fb610d503ebfda3b4d1553bac4
Author: Eric Anholt <[EMAIL PROTECTED]>
Date:   Wed Sep 5 13:10:43 2007 -0700

Bump version to 1.3.1.

diff --git a/configure.ac b/configure.ac
index dd26bca..63737ad 100644
--- a/configure.ac
+++ b/configure.ac
@@ -26,7 +26,7 @@ dnl Process this file with autoconf to create configure.
 AC_PREREQ([2.57])
 
 AC_INIT([libXfont],
-   1.3.0,
+   1.3.1,
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
libXfont)
 dnl

commit aca95d12a8b35de7ae914632fc9e8a723d58a860
Author: Matthieu Herrb <[EMAIL PROTECTED]>
Date:   Sat Aug 25 23:32:54 2007 +0200

Kill unused macro definition.

diff --git a/src/FreeType/fttools.c b/src/FreeType/fttools.c
index 002b62c..10604b1 100644
--- a/src/FreeType/fttools.c
+++ b/src/FreeType/fttools.c
@@ -43,13 +43,6 @@
 #include FT_TRUETYPE_IDS_H
 #include "ft.h"
 
-/* backward compatibility hack */
-#if (FREETYPE_VERSION < 2001008)
-# ifndef ft_isdigit
-#  define ft_isdigit isdigit
-# endif
-#endif
-
 #ifndef LSBFirst
 #define LSBFirst 0
 #define MSBFirst 1

commit 9f86614394af81bc484cf00f3e9996510d3718cb
Author: Ademar de Souza Reis Jr <[EMAIL PROTECTED]>
Date:   Mon Jul 30 14:36:21 2007 -0400

Fix dirfd leak on CatalogueRescan().

diff --git a/src/fontfile/catalogue.c b/src/fontfile/catalogue.c
index 8168ffd..33d4434 100644
--- a/src/fontfile/catalogue.c
+++ b/src/fontfile/catalogue.c
@@ -218,6 +218,8 @@ CatalogueRescan (FontPathElementPtr fpe)
}
 }
 
+closedir(dir);
+
 qsort(cat->fpeList,
  cat->fpeCount, sizeof cat->fpeList[0], ComparePriority);
 

commit 87f50267181887ed9214536608bd2035d2dd70f7
Author: Ademar de Souza Reis Jr <[EMAIL PROTECTED]>
Date:   Mon Jul 30 14:35:01 2007 -0400

Support relative paths in catalogue: symlinks.

Relative symlinks are common inside the catalogue directory and
should be supported as well.

diff --git a/src/fontfile/catalogue.c b/src/fontfile/catalogue.c
index 812b050..8168ffd 100644
--- a/src/fontfile/catalogue.c
+++ b/src/fontfile/catalogue.c
@@ -136,6 +136,7 @@ CatalogueRescan (FontPathElementPtr fpe)
 DIR*dir;
 struct dirent  *entry;
 intlen;
+intpathlen;
 
 path = fpe->name + strlen(CataloguePrefix);
 if (stat(path, &statbuf) < 0 || !S_ISDIR(statbuf.st_mode))
@@ -159,6 +160,17 @@ CatalogueRescan (FontPathElementPtr fpe)
if (len < 0)
continue;
 
+   dest[len] = '\0';
+
+   if (dest[0] != '/')
+   {
+  pathlen = strlen(path);
+  memmove(dest + pathlen + 1, dest, sizeof dest - pathlen - 1);
+  memcpy(dest, path, pathlen);
+  memcpy(dest + pathlen, "/", 1);
+  len += pathlen + 1;
+   }
+
attrib = strchr(link, ':');
if (attrib && len + strlen(attrib) < sizeof dest)
{

commit 32d2d335eacd1b55980323a71ef35cdf7c22366d
Author: Ademar de Souza Reis Jr <[EMAIL PROTECTED]>
Date:   Mon Jul 30 14:36:21 2007 -0400

Fix dirfd leak on CatalogueRescan().

diff --git a/src/fontfile/catalogue.c b/src/fontfile/catalogue.c
index 8168ffd..33d4434 100644
--- a/src/fontfile/catalogue.c
+++ b/src/fontfile/catalogue.c
@@ -218,6 +218,8 @@ CatalogueRescan (FontPathElementPtr fpe)
}
 }
 
+closedir(dir);
+
 qsort(cat->fpeList,
  cat->fpeCount, sizeof cat->fpeList[0], ComparePriority);
 

commit 0a5b31a40c4933f4c69157c61d4d4890af2205b1
Author: Ademar de Souza Reis Jr <[EMAIL PROTECTED]>
Date:   Mon Jul 30 14:35:01 2007 -0400

Support relative paths in catalogue: symlinks.

Relative symlinks are common inside the catalogue directory and
should be supported as well.

diff --git a/src/fontfile/catalogue.c b/src/fontfile/catalogue.c
index 812b050..8168ffd 100644
--- a/src/fontfile/catalogue.c
+++ b/src/fontfile/catalogue.c
@@ -136,6 +136,7 @@ CatalogueRescan (FontPathElementPtr fpe)
 DIR*dir;
 struct dirent  *entry;
 intlen;
+intpathlen;
 
 path = fpe->name + strlen(CataloguePrefix);
 if (stat(path, &statbuf) < 0 || !S_ISDIR(statbuf.st_mode))
@@ -159,6 +160,17 @@ CatalogueRescan (FontPathElementPtr fpe)
if (len < 0)
continue;
 
+   dest[len] = '\0';
+
+   if (dest[0] != '/')
+   {
+  pathlen = strlen(path);
+  memmove(dest + pathlen + 1, dest, sizeof dest - pathlen - 1);
+  memcpy(dest, path, pathlen);
+  memcpy(dest + pathlen, "/", 1);
+  len += pathlen + 1;
+   }
+
attrib = strchr(link, ':');
if (attrib && len + strlen(attrib) < sizeof dest)
{

commit

libxfont: Changes to 'upstream-unstable'

2007-06-22 Thread Drew Parsons
 configure.ac   |2 
 include/X11/fonts/bitmap.h |7 
 include/X11/fonts/bufio.h  |2 
 include/X11/fonts/fntfil.h |4 
 include/X11/fonts/pcf.h|2 
 src/FreeType/ft.h  |1 
 src/FreeType/fttools.c |   47 ---
 src/FreeType/xttcap.c  |  400 ++-
 src/FreeType/xttcap.h  |5 
 src/Speedo/do_char.c   |  207 --
 src/Speedo/do_trns.c   |   14 
 src/Speedo/out_scrn.c  |  172 +--
 src/Speedo/out_util.c  |  196 ++---
 src/Speedo/reset.c |2 
 src/Speedo/set_spcs.c  |   10 
 src/Speedo/set_trns.c  |  234 ---
 src/Speedo/spdo_prv.h  |  161 --
 src/Speedo/speedo.h|   16 -
 src/Speedo/spglyph.c   |2 
 src/Speedo/spint.h |2 
 src/Type1/Makefile.am  |1 
 src/Type1/arith.c  |  276 --
 src/Type1/arith.h  |6 
 src/Type1/digit.h  |2 
 src/Type1/fontfcn.c|   11 
 src/Type1/fontfcn.h|2 
 src/Type1/lines.c  |   69 ++--
 src/Type1/lines.h  |2 
 src/Type1/objects.c|  267 +++---
 src/Type1/objects.h|   39 --
 src/Type1/paths.c  |  662 -
 src/Type1/paths.h  |   34 --
 src/Type1/regions.c|  423 +++-
 src/Type1/regions.h|   26 -
 src/Type1/scanfont.c   |2 
 src/Type1/spaces.c |  221 +--
 src/Type1/spaces.h |   21 -
 src/Type1/t1funcs.c|   50 +--
 src/Type1/t1info.c |5 
 src/Type1/t1intf.h |1 
 src/Type1/t1malloc.c   |4 
 src/Type1/t1stub.c |   56 ---
 src/Type1/util.h   |1 
 src/bitmap/bitmapfunc.c|  100 +++---
 src/bitmap/bitscale.c  |6 
 src/bitmap/snfread.c   |2 
 src/bitmap/snfstr.h|1 
 src/builtins/builtin.h |8 
 src/builtins/dir.c |4 
 src/builtins/file.c|   19 -
 src/builtins/fonts.c   |   14 
 src/builtins/fpe.c |   23 -
 src/builtins/render.c  |   35 --
 src/fc/fsconvert.c |   40 --
 src/fc/fserve.c|   75 ++---
 src/fc/fserve.h|3 
 src/fc/fservestr.h |9 
 src/fc/fsio.c  |   62 
 src/fc/fsio.h  |7 
 src/fontfile/Makefile.am   |3 
 src/fontfile/bufio.c   |   22 -
 src/fontfile/catalogue.c   |  457 +++
 src/fontfile/fontfile.c|   41 +-
 src/fontfile/register.c|1 
 64 files changed, 1300 insertions(+), 3299 deletions(-)

New commits:
commit 8d47483711be6076e7bfefab14aa890c5f37e1aa
Author: Kristian Høgsberg <[EMAIL PROTECTED]>
Date:   Thu Jun 21 21:44:02 2007 -0400

Bump version to 1.2.9.

diff --git a/configure.ac b/configure.ac
index fb5cdec..379243a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -26,7 +26,7 @@ dnl Process this file with autoconf to create configure.
 AC_PREREQ([2.57])
 
 AC_INIT([libXfont],
-   1.2.8,
+   1.2.9,
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
libXfont)
 dnl

commit c5ab59762c4ad5def68436d55937a2bd558d5c99
Author: Kristian Høgsberg <[EMAIL PROTECTED]>
Date:   Tue Jun 19 10:38:02 2007 -0400

Add a new 'catalogue' FPE, which takes font paths from symlinks in a dir.

This patch adds a new FPE type, which will match font path elements of the
form

catalogue:

The dir specified after the catalogue: prefix will be scanned for symlinks
and each symlink destination will be added as a local fontfile FPE.
The symlink can be suffixed by attributes, such as 'unscaled', which
will be passed through to the underlying fontfile FPE.  Except the new
attribute 'pri' which will be used for ordering the fontfile FPEs.

An example configuration:

75dpi:unscaled:pri=20 -> /usr/share/X11/fonts/75dpi
ghostscript:pri=60 -> /usr/share/fonts/default/ghostscript
misc:unscaled:pri=10 -> /usr/share/X11/fonts/misc
type1:pri=40 -> /usr/share/X11/fonts/Type1
type1:pri=50 -> /usr/share/fonts/default/Type1

will add /usr/share/X11/fonts/misc as the first FPE with the attribute
'unscaled', second FPE will be /usr/share/X11/fonts/75dpi, also with
the attribute unscaled etc.  This is functionally equivalent to setting
the following font path:

/usr/share/X11/fonts/misc:unscaled,
/usr/share/X11/fonts/75dpi:unscaled,
/usr/share/X11/fonts/Type1,
/usr/share/fonts/default/Type1,
/usr/share/fonts/default/ghostscript

The motivation is to let font packages add a symlink to the new font
directory they provide instead of rewriting either the Xorg config file
or the xfs config file.

diff --git a/include/X11/fonts/fntfil.h b/include/X11/fonts/fntfil.h
index 81d2cbc..074f2d0 100644
--- a/include/X11/fonts/fntfil.h
+

libxfont: Changes to 'upstream-unstable'

2007-04-11 Thread Julien Cristau
 configure.ac |   13 +-
 src/bitmap/bdfread.c |   11 
 src/fontfile/ffcheck.c   |   60 +++
 src/fontfile/fontdir.c   |8 ++
 src/fontfile/register.c  |   60 +++
 src/stubs/Makefile.am|1 
 src/stubs/cauthgen.c |4 +++
 src/stubs/csignal.c  |4 +++
 src/stubs/delfntcid.c|4 +++
 src/stubs/errorf.c   |4 +++
 src/stubs/fatalerror.c   |4 +++
 src/stubs/findoldfnt.c   |4 +++
 src/stubs/fontmod.c  |   14 ++
 src/stubs/getcres.c  |4 +++
 src/stubs/getdefptsize.c |4 +++
 src/stubs/getnewfntcid.c |4 +++
 src/stubs/gettime.c  |4 +++
 src/stubs/initfshdl.c|4 +++
 src/stubs/regfpefunc.c   |4 +++
 src/stubs/rmfshdl.c  |4 +++
 src/stubs/servclient.c   |4 +++
 src/stubs/setfntauth.c   |4 +++
 src/stubs/stfntcfnt.c|4 +++
 src/stubs/xpstubs.c  |5 +++
 src/util/atom.c  |   12 +
 src/util/miscutil.c  |   12 -
 26 files changed, 218 insertions(+), 42 deletions(-)

New commits:
commit 87db45f5eb7880395735f7bf3a8ee2d89b7e0122
Author: Alan Coopersmith <[EMAIL PROTECTED]>
Date:   Wed Apr 4 17:05:13 2007 -0700

Version bump: 1.2.8

diff --git a/configure.ac b/configure.ac
index 0fa4307..fb5cdec 100644
--- a/configure.ac
+++ b/configure.ac
@@ -26,7 +26,7 @@ dnl Process this file with autoconf to create configure.
 AC_PREREQ([2.57])
 
 AC_INIT([libXfont],
-   1.2.7,
+   1.2.8,
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
libXfont)
 dnl

commit e7a59cfb5d442d2965cfcffeff405a4b05591190
Author: Matthieu Herrb <[EMAIL PROTECTED](none)>
Date:   Tue Apr 3 15:45:21 2007 +0200

Integer overflow vulnerabilities

CVE-2007-1351: BDFFont Parsing Integer Overflow
CVE-2007-1352: fonts.dir File Parsing Integer Overflow

diff --git a/src/bitmap/bdfread.c b/src/bitmap/bdfread.c
index acb77e9..a6f0c1e 100644
--- a/src/bitmap/bdfread.c
+++ b/src/bitmap/bdfread.c
@@ -65,6 +65,12 @@ from The Open Group.
 #include 
 #include 
 
+#if HAVE_STDINT_H
+#include 
+#elif !defined(INT32_MAX)
+#define INT32_MAX 0x7fff
+#endif
+
 #define INDICES 256
 #define MAXENCODING 0x
 #define BDFLINELEN  1024
@@ -288,6 +294,11 @@ bdfReadCharacters(FontFilePtr file, FontPtr pFont, 
bdfFileState *pState,
bdfError("invalid number of CHARS in BDF file\n");
return (FALSE);
 }
+if (nchars > INT32_MAX / sizeof(CharInfoRec)) {
+   bdfError("Couldn't allocate pCI (%d*%d)\n", nchars,
+sizeof(CharInfoRec));
+   goto BAILOUT;
+}
 ci = (CharInfoPtr) xalloc(nchars * sizeof(CharInfoRec));
 if (!ci) {
bdfError("Couldn't allocate pCI (%d*%d)\n", nchars,
diff --git a/src/fontfile/fontdir.c b/src/fontfile/fontdir.c
index aae1f2e..cf68a54 100644
--- a/src/fontfile/fontdir.c
+++ b/src/fontfile/fontdir.c
@@ -38,9 +38,17 @@ in this Software without prior written authorization from 
The Open Group.
 #include
 #include
 
+#if HAVE_STDINT_H
+#include 
+#elif !defined(INT32_MAX)
+#define INT32_MAX 0x7fff
+#endif
+
 Bool
 FontFileInitTable (FontTablePtr table, int size)
 {
+if (size < 0 || (size > INT32_MAX/sizeof(FontEntryRec))) 
+   return FALSE;
 if (size)
 {
table->entries = (FontEntryPtr) xalloc(sizeof(FontEntryRec) * size);

commit 0fbb37ccc630ced42d6a973c81d947870cca7637
Author: Alan Coopersmith <[EMAIL PROTECTED]>
Date:   Mon Apr 2 17:40:19 2007 -0700

Add #pragma weak for Sun cc where needed

diff --git a/src/stubs/cauthgen.c b/src/stubs/cauthgen.c
index 06f1a34..026c52d 100644
--- a/src/stubs/cauthgen.c
+++ b/src/stubs/cauthgen.c
@@ -3,6 +3,10 @@
 #endif
 #include "stubs.h"
 
+#ifdef __SUNPRO_C
+#pragma weak client_auth_generation
+#endif
+
 weak int
 client_auth_generation(ClientPtr client)
 {
diff --git a/src/stubs/csignal.c b/src/stubs/csignal.c
index 3e102cc..e6fdeae 100644
--- a/src/stubs/csignal.c
+++ b/src/stubs/csignal.c
@@ -3,6 +3,10 @@
 #endif
 #include "stubs.h"
 
+#ifdef __SUNPRO_C
+#pragma weak ClientSignal
+#endif
+
 weak Bool
 ClientSignal(ClientPtr client)
 {
diff --git a/src/stubs/delfntcid.c b/src/stubs/delfntcid.c
index 0b0a747..ca71328 100644
--- a/src/stubs/delfntcid.c
+++ b/src/stubs/delfntcid.c
@@ -3,6 +3,10 @@
 #endif
 #include "stubs.h"
 
+#ifdef __SUNPRO_C
+#pragma weak DeleteFontClientID
+#endif
+
 weak void
 DeleteFontClientID(Font id)
 {
diff --git a/src/stubs/errorf.c b/src/stubs/errorf.c
index 28872e2..fd32965 100644
--- a/src/stubs/errorf.c
+++ b/src/stubs/errorf.c
@@ -3,6 +3,10 @@
 #endif
 #include "stubs.h"
 
+#ifdef __SUNPRO_C
+#pragma weak ErrorF
+#endif
+
 weak void
 ErrorF(const char *f, ...)
 {
diff --git a/src/stubs/fatalerror.c b/src/stubs/fatalerror.c
index 295593e..1549ad3 100644
--- a/src/stubs/fatalerror.c
+++ b/src/stubs/fatalerror.c
@@ -3,6 +3,10 @@
 #endif
 #include "stubs.h"
 
+#ifdef __SUNPRO_C
+#pr

libxfont: Changes to 'upstream-unstable'

2007-01-23 Thread David Nusinow
New branch 'upstream-unstable' available with the following commits:
commit 9509d5c7ee5d5e78c6eef54e8faceede5ca5f24e
Author: Kristian Høgsberg <[EMAIL PROTECTED]>
Date:   Mon Jan 22 18:24:19 2007 -0500

Bump to 1.2.7.

commit 63af35b908b51690a6c12fd42b54cf4ee08c762a
Author: Simon Law <[EMAIL PROTECTED]>
Date:   Fri Jan 19 08:50:39 2007 +1100

fontfile: accept empty (but valid) font paths (bug #3091)
If a path has a valid fonts.dir or fonts.alias, but does not contain any
fonts (either fonts.dir specifies zero fonts, or fonts could not be
loaded), load it as a valid font path anyway.

commit 931b777108526dd0761f948dcd9f1603ac02efc8
Author: Kristian Høgsberg <[EMAIL PROTECTED]>
Date:   Wed Jan 17 17:19:53 2007 -0500

Add stubs for the scalable renderer callbacks.

Trying to scale a bitmap font provided by the built-in backend will
crash the X server as it calls into a NULL pointer.  This patch
adds "return BadFont;" stubs to prevent the crash.

commit 2e4ae1b524a0149479c46f3f12a9ce2413092442
Author: Daniel Stone <[EMAIL PROTECTED]>
Date:   Sat Dec 16 00:53:43 2006 +0200

bump to 1.2.6

commit facc7ce4892eab4353fff0f45d2d3fd6be7d3e3d
Author: Daniel Stone <[EMAIL PROTECTED]>
Date:   Sat Dec 16 00:53:32 2006 +0200

build Type1 by default
Build Type1 by default, instead of needing to explicitly enable it.

commit 257db35656d5bf9385080e1d173260f0076f849c
Author: Daniel Stone <[EMAIL PROTECTED]>
Date:   Sat Dec 16 00:53:07 2006 +0200

don't distribute fontconf.h
Since fontconf.h is a generated file, don't distribute it.

commit ab0f05dcfb5537ba5aec7e48ddb713d4fdba7e75
Author: Daniel Stone <[EMAIL PROTECTED]>
Date:   Wed Dec 6 18:53:54 2006 +0200

Makefile.am: make ChangeLog hook safer
Make ChangeLog hook as safe as possible.

commit da20e256b786eaa6357e3d55baa9e90e38f14614
Author: Daniel Stone <[EMAIL PROTECTED]>
Date:   Fri Dec 1 01:05:59 2006 +0200

bump to 1.2.5

commit 16a0c282a673136c0bbb116f35e6e89d8b43a877
Author: Daniel Stone <[EMAIL PROTECTED]>
Date:   Fri Dec 1 01:05:40 2006 +0200

post-CID fixes
Curiously, make distcheck succeeded ... go figure.

commit e47fb944a8f485c4ad6be9c2cf6a4866eff7a07f
Author: Daniel Stone <[EMAIL PROTECTED]>
Date:   Fri Dec 1 00:35:48 2006 +0200

bump to 1.2.4

commit 47084ba39920068030c3e59523701d1205161a9f
Author: Daniel Stone <[EMAIL PROTECTED]>
Date:   Fri Dec 1 00:35:04 2006 +0200

remove CID font support (bug #5553)
Remove non-free CID font support, which was unused anyway.

commit c4741cdd83bcdedcc6f7a072a73b16668fc905eb
Author: Adam Jackson <[EMAIL PROTECTED]>
Date:   Fri Oct 13 16:17:26 2006 -0400

Bump to 1.2.3

commit 5dfff0eb0f532edb1f4a25daa5529e08dd832ecb
Author: Alan Coopersmith <[EMAIL PROTECTED]>
Date:   Thu Oct 5 18:12:50 2006 -0700

--disable-builtins should not force off all bitmap support

commit 264df52d24f585915e0d9823d5f087cf23e3fc75
Merge: 0fb55cb86e2ec5dbfbf27a01ceafb77c72fe9f40 
d896c3eaeafdb8831ed0833af46250c36f82502f
Author: Alan Coopersmith <[EMAIL PROTECTED]>
Date:   Fri Sep 22 11:36:43 2006 -0700

Merge branch 'master' of git+ssh://git.freedesktop.org/git/xorg/lib/libXfont

commit d896c3eaeafdb8831ed0833af46250c36f82502f
Author: Adam Jackson <[EMAIL PROTECTED]>
Date:   Tue Sep 12 11:11:12 2006 -0400

Fix distcheck.

commit 1bb49c77c321fab1f5c268404ea0ec622fa083ed
Author: Adam Jackson <[EMAIL PROTECTED]>
Date:   Tue Sep 12 11:01:13 2006 -0400

Bump to 1.2.2.

commit 8c8203ca2760105aca4e0b6ec5909355a061f0b3
Author: Matthieu Herrb <[EMAIL PROTECTED]>
Date:   Tue Sep 12 13:50:31 2006 +0200

Fixes for integer overflows in CID encoded fonts parsing reported by 
iDefense
CVE-ID 2006-3739, 2006-3740, bugzilla #8000, #8001.

commit 0fb55cb86e2ec5dbfbf27a01ceafb77c72fe9f40
Author: Alan Coopersmith <[EMAIL PROTECTED]>
Date:   Wed Aug 30 15:53:14 2006 -0700

Fix typo in comment (alreadt -> already)

commit aa7f3107d5aad41cb3f7b1bb3a4723014314289c
Author: Alan Coopersmith <[EMAIL PROTECTED]>
Date:   Fri Aug 25 17:51:46 2006 -0700

Add *~ to .gitignore to skip emacs droppings

commit cd09f4d54045b957d728d853398d62543d687d03
Author: Alan Coopersmith <[EMAIL PROTECTED]>
Date:   Fri Aug 25 17:51:04 2006 -0700

Replace static ChangeLog with dist-hook to generate from git log

commit 8d171fe61e564d8ed8f75034d4191062cecf190b
Author: Matthieu Herrb <[EMAIL PROTECTED]>
Date:   Sun Jul 23 22:42:43 2006 +0200

More check on PCF file reading. Bugzilla #7535

commit fead0fa3bae0ba5a4744d6a2aee1caa08019f344
Author: Daniel Stone <[EMAIL PROTECTED]>
Date:   Wed Jul 19 18:03:58 2006 -0400

use OpenBitmap when available
Don't just use OpenScalable unconditionally.  Fixes builtin fonts.

commit 13422d0e0468f2ddf7cb74cbf925e5bcf4551ae7
Author: Daniel Stone <[EMAIL PROTECTED]>
Date:   Wed Jul 19 18:03:26 2006 -0400

move builtin fonts to gzip
Use gzip, rather than compress, for builtin fonts.

commit 47ca9941396a375f5e22c220327b