From 467e33d1b198ac1a2b0df8972407a4539eee430d Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Thu, 30 Dec 2004 23:42:02 +0000 Subject: Make the "col_data" field in a "column_info" structure a pointer to an array of "const char *" rather than to an array of "char *", and make the second argument of "col_set_str()" a "const char *" - there's no guarantee that "col_data" points to something you're allowed to modify. svn path=/trunk/; revision=12875 --- print.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'print.c') diff --git a/print.c b/print.c index d1ffd14cb2..a95e3c859b 100644 --- a/print.c +++ b/print.c @@ -76,7 +76,7 @@ static gboolean print_hex_data_buffer(print_stream_t *stream, const guchar *cp, guint length, char_enc encoding); static void ps_clean_string(unsigned char *out, const unsigned char *in, int outbuf_size); -static void print_escaped_xml(FILE *fh, char *unescaped_string); +static void print_escaped_xml(FILE *fh, const char *unescaped_string); static void print_pdml_geninfo(proto_tree *tree, FILE *fh); @@ -561,9 +561,9 @@ get_field_data(GSList *src_list, field_info *fi) /* Print a string, escaping out certain characters that need to * escaped out for XML. */ static void -print_escaped_xml(FILE *fh, char *unescaped_string) +print_escaped_xml(FILE *fh, const char *unescaped_string) { - unsigned char *p; + const unsigned char *p; for (p = unescaped_string; *p != '\0'; p++) { switch (*p) { -- cgit v1.2.3