diff options
author | Bill Meier <wmeier@newsguy.com> | 2008-05-11 18:33:49 +0000 |
---|---|---|
committer | Bill Meier <wmeier@newsguy.com> | 2008-05-11 18:33:49 +0000 |
commit | fe5c2d98205e726a049ae1c5f2ac5013c6bda60b (patch) | |
tree | 2c5118a7646e1fa773f2a668ffa4cae5cedb3c5d /epan | |
parent | 319f71c537bf55a7cdfe0ea51d1909ad24c6491b (diff) | |
download | wireshark-fe5c2d98205e726a049ae1c5f2ac5013c6bda60b.tar.gz |
g_string_sprintf --> g_string_printf and g_string_sprintfa --> g_string_append_printf
svn path=/trunk/; revision=25276
Diffstat (limited to 'epan')
-rw-r--r-- | epan/dfilter/dfilter-macro.c | 6 | ||||
-rw-r--r-- | epan/dtd_grammar.lemon | 6 | ||||
-rw-r--r-- | epan/dtd_parse.l | 4 | ||||
-rw-r--r-- | epan/dtd_preparse.l | 10 | ||||
-rw-r--r-- | epan/radius_dict.l | 8 | ||||
-rw-r--r-- | epan/wslua/wslua_field.c | 2 | ||||
-rw-r--r-- | epan/wslua/wslua_proto.c | 4 |
7 files changed, 20 insertions, 20 deletions
diff --git a/epan/dfilter/dfilter-macro.c b/epan/dfilter/dfilter-macro.c index 179a5f00a3..4242c833cd 100644 --- a/epan/dfilter/dfilter-macro.c +++ b/epan/dfilter/dfilter-macro.c @@ -202,9 +202,9 @@ static gchar* dfilter_macro_resolve(gchar* name, gchar** args, const gchar** err if (args) { while (*parts) { - g_string_sprintfa(text,"%s%s", - args[*(arg_pos_p++)], - *(parts++)); + g_string_append_printf(text,"%s%s", + args[*(arg_pos_p++)], + *(parts++)); } } diff --git a/epan/dtd_grammar.lemon b/epan/dtd_grammar.lemon index 1b56e52a3d..3fc63e2e55 100644 --- a/epan/dtd_grammar.lemon +++ b/epan/dtd_grammar.lemon @@ -69,13 +69,13 @@ static GPtrArray* g_ptr_array_join(GPtrArray* a, GPtrArray* b){ %syntax_error { if (!TOKEN) - g_string_sprintfa(bd->error,"syntax error at end of file"); + g_string_append_printf(bd->error,"syntax error at end of file"); else - g_string_sprintfa(bd->error,"syntax error in %s at or before '%s': \n", TOKEN->location,TOKEN->text); + g_string_append_printf(bd->error,"syntax error in %s at or before '%s': \n", TOKEN->location,TOKEN->text); } %parse_failure { - g_string_sprintfa(bd->error,"DTD parsing failure\n"); + g_string_append_printf(bd->error,"DTD parsing failure\n"); } %token_prefix TOKEN_ diff --git a/epan/dtd_parse.l b/epan/dtd_parse.l index 4556a05858..05c8a611b8 100644 --- a/epan/dtd_parse.l +++ b/epan/dtd_parse.l @@ -218,7 +218,7 @@ squoted ['][^\']*['] <GET_ATTR_QUOTE>{get_attr_quote} { BEGIN GET_ATTR_VAL; } <GET_ATTR_QUOTE>. { - g_string_sprintfa(build_data->error, + g_string_append_printf(build_data->error, "error in wireshark:protocol xmpli at %s : could not find attribute value!", location); yyterminate(); @@ -238,7 +238,7 @@ squoted ['][^\']*['] } if (! got_it) { - g_string_sprintfa(build_data->error, + g_string_append_printf(build_data->error, "error in wireshark:protocol xmpli at %s : no such parameter %s!", location, attr_name); g_free(attr_name); diff --git a/epan/dtd_preparse.l b/epan/dtd_preparse.l index 7a8fa5e8d0..9325718389 100644 --- a/epan/dtd_preparse.l +++ b/epan/dtd_preparse.l @@ -122,7 +122,7 @@ newline \n %% -{entity} if (current) g_string_sprintfa(current,"%s\n%s\n",replace_entity(yytext),location()); +{entity} if (current) g_string_append_printf(current,"%s\n%s\n",replace_entity(yytext),location()); {whitespace} if (current) g_string_append(current," "); @@ -138,7 +138,7 @@ newline \n {newline} { linenum++; - if (current) g_string_sprintfa(current,"%s\n",location()); + if (current) g_string_append_printf(current,"%s\n",location()); } @@ -150,7 +150,7 @@ newline \n <IN_QUOTE>{non_quote} | <IN_QUOTE>{escaped_quote} g_string_append(current,yytext); <NAMED_ENTITY>{system} { - g_string_sprintfa(error,"at %s:%u: file inclusion is not supported!", filename, linenum); + g_string_append_printf(error,"at %s:%u: file inclusion is not supported!", filename, linenum); yyterminate(); } <ENTITY_DONE>{special_stop} { current = output; g_string_append(current,"\n"); BEGIN OUTSIDE; } @@ -167,7 +167,7 @@ static gchar* replace_entity(gchar* entity) { if (replacement) { return replacement->str; } else { - g_string_sprintfa(error,"dtd_preparse: in file '%s': entity %s does not exists\n", filename, entity); + g_string_append_printf(error,"dtd_preparse: in file '%s': entity %s does not exists\n", filename, entity); return ""; } @@ -200,7 +200,7 @@ extern GString* dtd_preparse(const gchar* dname,const gchar* fname, GString* er if (!yyin) { if (err) - g_string_sprintfa(err, "Could not open file: '%s', error: %s",fullname,strerror(errno)); + g_string_append_printf(err, "Could not open file: '%s', error: %s",fullname,strerror(errno)); return NULL; } diff --git a/epan/radius_dict.l b/epan/radius_dict.l index 5fc91d0700..6ae9623139 100644 --- a/epan/radius_dict.l +++ b/epan/radius_dict.l @@ -189,7 +189,7 @@ <INCLUDE>[^[:blank:]\n]+ { if ( include_stack_ptr >= MAX_INCLUDE_DEPTH ) { - g_string_sprintfa(error, "$INCLUDE files nested to deeply\n"); + g_string_append_printf(error, "$INCLUDE files nested to deeply\n"); yyterminate(); } @@ -202,7 +202,7 @@ if (!yyin) { if (errno) { - g_string_sprintfa(error, "Could not open file: '%s', error: %s\n", fullpaths[include_stack_ptr], strerror(errno) ); + g_string_append_printf(error, "Could not open file: '%s', error: %s\n", fullpaths[include_stack_ptr], strerror(errno) ); yyterminate(); } } else { @@ -258,7 +258,7 @@ void add_attribute(const gchar* name, const gchar* code, radius_attr_dissector_ v = g_hash_table_lookup(dict->vendors_by_name,vendor_name); if (! v) { - g_string_sprintfa(error, "Vendor: '%s', does not exist in %s:%i \n", vendor_name, fullpaths[include_stack_ptr], linenums[include_stack_ptr] ); + g_string_append_printf(error, "Vendor: '%s', does not exist in %s:%i \n", vendor_name, fullpaths[include_stack_ptr], linenums[include_stack_ptr] ); BEGIN JUNK; return; } else { @@ -385,7 +385,7 @@ gboolean radius_load_dictionary (radius_dictionary_t* d, gchar* dir, const gchar yyin = eth_fopen(fullpaths[include_stack_ptr],"r"); if (!yyin) { - g_string_sprintfa(error, "Could not open file: '%s', error: %s\n", fullpaths[include_stack_ptr], strerror(errno) ); + g_string_append_printf(error, "Could not open file: '%s', error: %s\n", fullpaths[include_stack_ptr], strerror(errno) ); g_free(fullpaths[include_stack_ptr]); *err_str = error->str; g_string_free(error,FALSE); diff --git a/epan/wslua/wslua_field.c b/epan/wslua/wslua_field.c index 209e47df5e..30220d7057 100644 --- a/epan/wslua/wslua_field.c +++ b/epan/wslua/wslua_field.c @@ -343,7 +343,7 @@ void lua_prime_all_fields(proto_tree* tree _U_) { g_free(name); - g_string_sprintfa(fake_tap_filter," || %s",(*f)->abbrev); + g_string_append_printf(fake_tap_filter," || %s",(*f)->abbrev); fake_tap = TRUE; } diff --git a/epan/wslua/wslua_proto.c b/epan/wslua/wslua_proto.c index 28cf501843..d4424e528c 100644 --- a/epan/wslua/wslua_proto.c +++ b/epan/wslua/wslua_proto.c @@ -1604,7 +1604,7 @@ WSLUA_METAMETHOD DissectorTable_tostring(lua_State* L) { switch(type) { case FT_STRING: { - g_string_sprintfa(s,"%s String:\n",dt->name); + g_string_append_printf(s,"%s String:\n",dt->name); break; } case FT_UINT8: @@ -1613,7 +1613,7 @@ WSLUA_METAMETHOD DissectorTable_tostring(lua_State* L) { case FT_UINT32: { int base = get_dissector_table_base(dt->name); - g_string_sprintfa(s,"%s Integer(%i):\n",dt->name,base); + g_string_append_printf(s,"%s Integer(%i):\n",dt->name,base); break; } default: |