From e125fb2cf60581e98bc6e7a65a818533fe1917c4 Mon Sep 17 00:00:00 2001 From: dos-reis Date: Sun, 19 Aug 2012 01:25:10 +0000 Subject: * include/sockio.h (connect_to_local_server): First parameter now const char*. * include/pixmap.h (zzopen): Second parameter now const char*. * lib/pixmap.c: Propagate change. * lib/sockio-c.c: Likewise. * hyper/parse-types.c (parse_verbatim): Tidy. * hyper/spadint.c (print_source_to_string1): Likewise. * hyper/initx.h (init_top_window): Change parameter type to const char*. * hyper/initx.c: Propagate change. * hyper/titlebar.c: Tidy. (set_name_and_icon): icon_name is now of type const char*. (get_border_properties): bwidth is not of type const char*. (mergeDatabases): classname is now of type const char*. (is_it_850): probtbl.name is now of type const char*. --- src/hyper/initx.c | 10 +++++----- src/hyper/initx.h | 2 +- src/hyper/parse-types.c | 4 +++- src/hyper/spadint.c | 2 +- src/hyper/titlebar.c | 10 +++++----- 5 files changed, 15 insertions(+), 13 deletions(-) (limited to 'src/hyper') diff --git a/src/hyper/initx.c b/src/hyper/initx.c index 9dc6fb66..4cfae4ef 100644 --- a/src/hyper/initx.c +++ b/src/hyper/initx.c @@ -219,7 +219,7 @@ initializeWindowSystem(void) */ int -init_top_window(char *name) +init_top_window(const char *name) { HyperDocPage *page; XSetWindowAttributes wa; /* The X attributes structure */ @@ -377,7 +377,7 @@ init_form_window(char *name, int cols) static void set_name_and_icon(void) { - char *icon_name = "HyperDoc"; + const char *icon_name = "HyperDoc"; char *s; Pixmap icon_pixmap; XWMHints wmhints; @@ -410,7 +410,7 @@ set_name_and_icon(void) static int get_border_properties(void) { - char *bwidth; + const char *bwidth; /*char *bc = NULL;*/ int bw; /*XColor color_def, color_db;*/ @@ -953,7 +953,7 @@ mergeDatabases(void) XrmDatabase homeDB, serverDB, applicationDB; char filenamebuf[1024]; char *filename = &filenamebuf[0]; - char *classname = "OpenAxiom"; + const char *classname = "OpenAxiom"; char name[255]; /* fprintf(stderr,"initx:mergeDatabases:entered\n");*/ @@ -1003,7 +1003,7 @@ is_it_850(XFontStruct *fontarg) char *s; int i,val; static struct { - char *name; + const char *name; Atom format; Atom atom; } proptbl = { "CHARSET_ENCODING", XA_ATOM }; diff --git a/src/hyper/initx.h b/src/hyper/initx.h index 7005ba3b..fe043968 100644 --- a/src/hyper/initx.h +++ b/src/hyper/initx.h @@ -40,7 +40,7 @@ extern void change_text(int color , XFontStruct * font); extern int init_form_window(char * name , int cols); -extern int init_top_window(char * name); +extern int init_top_window(const char * name); extern void initializeWindowSystem(void); extern int is_it_850(XFontStruct * fontarg); diff --git a/src/hyper/parse-types.c b/src/hyper/parse-types.c index a548347a..e20d77b3 100644 --- a/src/hyper/parse-types.c +++ b/src/hyper/parse-types.c @@ -356,7 +356,9 @@ void parse_verbatim(int type) { int size = 0, c; - char *end_string, *vb = vbuf, *es; + char *vb = vbuf; + const char *end_string; + const char* es; curr_node->type = type; if (token.id[-1]) diff --git a/src/hyper/spadint.c b/src/hyper/spadint.c index 20d1b2a2..d31ed6da 100644 --- a/src/hyper/spadint.c +++ b/src/hyper/spadint.c @@ -920,7 +920,7 @@ char * print_source_to_string1(TextNode *command,int * sizeBuf) { char *c = p2sBuf; - char *s; + const char *s; InputItem *item; LineStruct *curr_line; int lcount; diff --git a/src/hyper/titlebar.c b/src/hyper/titlebar.c index 6cf37472..23f20f57 100644 --- a/src/hyper/titlebar.c +++ b/src/hyper/titlebar.c @@ -83,11 +83,11 @@ static char *noopfile = "noop.bitmap"; #else -static char *tw1file = "exit3d.bitmap"; -static char *tw2file = "help3d.bitmap"; -static char *tw3file = "home3d.bitmap"; -static char *tw4file = "up3d.bitmap"; -static char *noopfile = "noop3d.bitmap"; +static const char* tw1file = "exit3d.bitmap"; +static const char* tw2file = "help3d.bitmap"; +static const char* tw3file = "home3d.bitmap"; +static const char* tw4file = "up3d.bitmap"; +static const char* noopfile = "noop3d.bitmap"; #define BACKCOLOR gControlBackgroundColor #define BUTTGC fControlGC -- cgit v1.2.3