From 447b3268bfb2d6a92d105ad75c2ac5462f1adecb Mon Sep 17 00:00:00 2001 From: Alan Coopersmith Date: Fri, 11 Nov 2011 22:54:21 -0800 Subject: Mark pattern argument to FSListFonts* as const char * Needed to fix gcc -Wwrite-strings warnings in clients such as fslsfonts Signed-off-by: Alan Coopersmith --- doc/FSlib.txt | 4 ++-- include/X11/fonts/FSlib.h | 4 ++-- src/FSFontInfo.c | 2 +- src/FSFtNames.c | 2 +- src/FSlibInt.c | 4 ++-- src/FSlibint.h | 2 +- 6 files changed, 9 insertions(+), 9 deletions(-) diff --git a/doc/FSlib.txt b/doc/FSlib.txt index d67fff1..5f686f3 100644 --- a/doc/FSlib.txt +++ b/doc/FSlib.txt @@ -42,7 +42,7 @@ Closes the font. char ** FSListFonts( FSServer *svr, - char *pattern, + const char *pattern, int maxNames, int *actualCount); @@ -59,7 +59,7 @@ Frees the list of font names returned by FSListFonts. char ** FSListFontsWithXInfo( FSServer *svr, - char *pattern, + const char *pattern, int maxNames, int *actualCount, fsFontHeader ***info, diff --git a/include/X11/fonts/FSlib.h b/include/X11/fonts/FSlib.h index fbc2dc9..11b3ba6 100644 --- a/include/X11/fonts/FSlib.h +++ b/include/X11/fonts/FSlib.h @@ -258,9 +258,9 @@ extern char ** FSGetCatalogues ( FSServer *svr, int *num ); extern long FSMaxRequestSize ( FSServer *svr ); -extern char ** FSListFonts ( FSServer *svr, char *pattern, int maxNames, +extern char ** FSListFonts ( FSServer *svr, const char *pattern, int maxNames, int *actualCount ); -extern char ** FSListFontsWithXInfo ( FSServer *svr, char *pattern, +extern char ** FSListFontsWithXInfo ( FSServer *svr, const char *pattern, int maxNames, int *count, FSXFontInfoHeader ***info, FSPropInfo ***pprops, diff --git a/src/FSFontInfo.c b/src/FSFontInfo.c index 3d449bf..d9c84b6 100644 --- a/src/FSFontInfo.c +++ b/src/FSFontInfo.c @@ -56,7 +56,7 @@ in this Software without prior written authorization from The Open Group. char ** FSListFontsWithXInfo( FSServer *svr, - char *pattern, + const char *pattern, int maxNames, int *count, FSXFontInfoHeader ***info, diff --git a/src/FSFtNames.c b/src/FSFtNames.c index 7d21efb..9624205 100644 --- a/src/FSFtNames.c +++ b/src/FSFtNames.c @@ -57,7 +57,7 @@ in this Software without prior written authorization from The Open Group. char ** FSListFonts( FSServer *svr, - char *pattern, + const char *pattern, int maxNames, int *actualCount) { diff --git a/src/FSlibInt.c b/src/FSlibInt.c index 5a33b64..eea9840 100644 --- a/src/FSlibInt.c +++ b/src/FSlibInt.c @@ -536,7 +536,7 @@ _FSReadPad( void _FSSend( register FSServer *svr, - char *data, + const char *data, register long size) { struct iovec iov[3]; @@ -591,7 +591,7 @@ _FSSend( } InsertIOV(svr->buffer, svrbufsize) - InsertIOV(data, size) + InsertIOV((char *)data, size) InsertIOV(pad, padsize) ESET(0); diff --git a/src/FSlibint.h b/src/FSlibint.h index b44b153..d5a66b8 100644 --- a/src/FSlibint.h +++ b/src/FSlibint.h @@ -74,7 +74,7 @@ extern void _FSFlush ( FSServer *svr ); extern void _FSRead ( FSServer *svr, char *data, long size ); extern void _FSReadEvents ( FSServer *svr ); extern void _FSReadPad ( FSServer *svr, char *data, long size ); -extern void _FSSend ( FSServer *svr, char *data, long size ); +extern void _FSSend ( FSServer *svr, const char *data, long size ); extern void _FSEnq ( FSServer *svr, fsEvent *event ); extern void _FSFreeServerStructure ( FSServer *svr ); extern int _FSError ( FSServer *svr, fsError *rep ); -- cgit v1.2.3