aboutsummaryrefslogtreecommitdiff
path: root/libXfont/src/fc/fserve.c
diff options
context:
space:
mode:
Diffstat (limited to 'libXfont/src/fc/fserve.c')
-rw-r--r--libXfont/src/fc/fserve.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/libXfont/src/fc/fserve.c b/libXfont/src/fc/fserve.c
index 1e1093cd5..92b0d53da 100644
--- a/libXfont/src/fc/fserve.c
+++ b/libXfont/src/fc/fserve.c
@@ -147,7 +147,7 @@ static void
_fs_close_server (FSFpePtr conn);
static FSFpePtr
-_fs_init_conn (char *servername);
+_fs_init_conn (const char *servername);
static int
_fs_wait_connect (FSFpePtr conn);
@@ -235,7 +235,7 @@ _fs_add_rep_log (FSFpePtr conn, fsGenericReply *rep)
#endif
static Bool
-fs_name_check(char *name)
+fs_name_check(const char *name)
{
/* Just make sure there is a protocol/ prefix */
return (name && *name != '/' && strchr(name, '/'));
@@ -293,7 +293,7 @@ static int
fs_init_fpe(FontPathElementPtr fpe)
{
FSFpePtr conn;
- char *name;
+ const char *name;
int err;
int ret;
@@ -1615,7 +1615,7 @@ _fs_do_blocked (FSFpePtr conn)
/* ARGSUSED */
static int
fs_send_open_font(pointer client, FontPathElementPtr fpe, Mask flags,
- char *name, int namelen,
+ const char *name, int namelen,
fsBitmapFormat format, fsBitmapFormatMask fmask,
XID id, FontPtr *ppfont)
{
@@ -1633,7 +1633,7 @@ fs_send_open_font(pointer client, FontPathElementPtr fpe, Mask flags,
if (conn->blockState & FS_GIVE_UP)
return BadFontName;
- if (namelen <= 0 || namelen > sizeof (buf) - 1)
+ if (namelen < 0 || namelen > sizeof (buf) - 1)
return BadFontName;
/*
@@ -1807,7 +1807,7 @@ fs_send_query_bitmaps(FontPathElementPtr fpe, FSBlockDataPtr blockrec)
/* ARGSUSED */
static int
fs_open_font(pointer client, FontPathElementPtr fpe, Mask flags,
- char *name, int namelen,
+ const char *name, int namelen,
fsBitmapFormat format, fsBitmapFormatMask fmask,
XID id, FontPtr *ppfont,
char **alias, FontPtr non_cachable_font)
@@ -2161,7 +2161,7 @@ fs_send_load_glyphs(pointer client, FontPtr pfont,
}
-extern pointer serverClient; /* This could be any number that
+extern pointer __GetServerClient(void); /* This could be any number that
doesn't conflict with existing
client values. */
@@ -2333,17 +2333,17 @@ fs_load_all_glyphs(FontPtr pfont)
* perform an unpleasant job that, we hope, will never be required.
*/
- while ((err = _fs_load_glyphs(serverClient, pfont, TRUE, 0, 0, NULL)) ==
+ while ((err = _fs_load_glyphs(__GetServerClient(), pfont, TRUE, 0, 0, NULL)) ==
Suspended)
{
if (fs_await_reply (conn) != FSIO_READY)
{
/* Get rid of blockrec */
- fs_client_died(serverClient, pfont->fpe);
+ fs_client_died(__GetServerClient(), pfont->fpe);
err = BadCharRange;
break;
}
- fs_read_reply (pfont->fpe, serverClient);
+ fs_read_reply (pfont->fpe, __GetServerClient());
}
return err;
}
@@ -2403,7 +2403,7 @@ fs_read_list(FontPathElementPtr fpe, FSBlockDataPtr blockrec)
}
static int
-fs_send_list_fonts(pointer client, FontPathElementPtr fpe, char *pattern,
+fs_send_list_fonts(pointer client, FontPathElementPtr fpe, const char *pattern,
int patlen, int maxnames, FontNamesPtr newnames)
{
FSFpePtr conn = (FSFpePtr) fpe->private;
@@ -2459,7 +2459,7 @@ fs_send_list_fonts(pointer client, FontPathElementPtr fpe, char *pattern,
static int
fs_list_fonts(pointer client, FontPathElementPtr fpe,
- char *pattern, int patlen, int maxnames, FontNamesPtr newnames)
+ const char *pattern, int patlen, int maxnames, FontNamesPtr newnames)
{
FSFpePtr conn = (FSFpePtr) fpe->private;
FSBlockDataPtr blockrec;
@@ -2630,7 +2630,7 @@ done:
/* ARGSUSED */
static int
fs_start_list_with_info(pointer client, FontPathElementPtr fpe,
- char *pattern, int len, int maxnames, pointer *pdata)
+ const char *pattern, int len, int maxnames, pointer *pdata)
{
FSFpePtr conn = (FSFpePtr) fpe->private;
FSBlockDataPtr blockrec;
@@ -3362,7 +3362,7 @@ _fs_start_reconnect (FSFpePtr conn)
static FSFpePtr
-_fs_init_conn (char *servername)
+_fs_init_conn (const char *servername)
{
FSFpePtr conn;