diff options
author | Guy Harris <guy@alum.mit.edu> | 2014-02-23 14:16:24 -0800 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2014-02-26 22:04:08 +0000 |
commit | 8d234a0d8c6c974a374e36a58cd7b3d699866464 (patch) | |
tree | 9306a7d3b231b5134e1773de238b89fb6dfe9cc8 /epan/tvbuff.c | |
parent | 1dff4e309d036e23c316f2cf9a6d05d5a4449ff2 (diff) | |
download | wireshark-8d234a0d8c6c974a374e36a58cd7b3d699866464.tar.gz |
More tvbuff API deprecation, comment expansion, and documentation updates.
Do with tvb_get_stringz() what was done with tvb_get_string().
Redo the comments for the string get routines to try to give more detail
in a fashion that's a bit less hard to read.
Warn, in comments, of the problems with using
tvb_get_string()/tvb_get_stringz() (i.e., if your strings are non-ASCII,
all bytes with the 8th bit set are going be replaced by the Unicode
REPLACEMENT CHARACTER, and displayed as such).
Warn, in a comment, of the problems with tvb_get_const_stringz() (i.e.,
it gives you raw bytes, rather than guaranteed-to-be-valid UTF-8).
Update documentation and release notes appropriately.
Change-Id: Ibd3efb92a203861f507ce71bc8d04d19d9d38a93
Reviewed-on: https://code.wireshark.org/review/327
Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'epan/tvbuff.c')
-rw-r--r-- | epan/tvbuff.c | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/epan/tvbuff.c b/epan/tvbuff.c index 945ab95f9c..6458382497 100644 --- a/epan/tvbuff.c +++ b/epan/tvbuff.c @@ -2770,16 +2770,6 @@ tvb_get_stringz_enc(wmem_allocator_t *scope, tvbuff_t *tvb, const gint offset, g return strptr; } -/* - * Get an ASCII string; this should not be used in new code. - */ -guint8 * -tvb_get_stringz(wmem_allocator_t *scope, tvbuff_t *tvb, const gint offset, - gint *lengthp) -{ - return tvb_get_ascii_stringz(scope, tvb, offset, lengthp); -} - /* Looks for a stringz (NUL-terminated string) in tvbuff and copies * no more than bufsize number of bytes, including terminating NUL, to buffer. * Returns length of string (not including terminating NUL), or -1 if the string was |