diff options
author | Guy Harris <guy@alum.mit.edu> | 2011-07-03 17:08:25 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2011-07-03 17:08:25 +0000 |
commit | 338af96b2e28196d8dc800a6ca844108bc8f3041 (patch) | |
tree | c14e85b721dcab2bb7cadd9787bffc7a551cb2e2 /epan/tvbuff.h | |
parent | 8b303cc61a85c3efdb37171d21702ac112681e26 (diff) |
Add a tvb_get_ephemeral_string_enc() routine that's like
tvb_get_ephemeral_string() but takes an ENC_ value for the character
encoding. Use it in the MQ dissector to fetch strings to put, for
example, into the Info column, so we properly handle EBCDIC strings
there.
svn path=/trunk/; revision=37876
Diffstat (limited to 'epan/tvbuff.h')
-rw-r--r-- | epan/tvbuff.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/epan/tvbuff.h b/epan/tvbuff.h index 4a187332cb..8552e2dc78 100644 --- a/epan/tvbuff.h +++ b/epan/tvbuff.h @@ -442,6 +442,9 @@ extern gchar *tvb_format_stringzpad_wsp(tvbuff_t *tvb, const gint offset, const * instead it will automatically be freed once the next * packet is dissected. * + * tvb_get_ephemeral_string_enc() takes a string encoding as well, and + * converts to UTF-8 from the encoding (only UTF-8 and EBCDIC supported) + * * tvb_get_ephemeral_unicode_string() Unicode (UTF-16) version of above * * tvb_get_seasonal_string() returns a string that does not need to be freed, @@ -451,6 +454,8 @@ extern gchar *tvb_format_stringzpad_wsp(tvbuff_t *tvb, const gint offset, const extern guint8 *tvb_get_string(tvbuff_t *tvb, const gint offset, const gint length); extern gchar *tvb_get_unicode_string(tvbuff_t *tvb, const gint offset, gint length, const guint encoding); extern guint8 *tvb_get_ephemeral_string(tvbuff_t *tvb, const gint offset, const gint length); +extern guint8 *tvb_get_ephemeral_string_enc(tvbuff_t *tvb, const gint offset, + const gint length, const gint encoding); extern gchar *tvb_get_ephemeral_unicode_string(tvbuff_t *tvb, const gint offset, gint length, const guint encoding); extern guint8 *tvb_get_seasonal_string(tvbuff_t *tvb, const gint offset, const gint length); |