diff options
author | Guy Harris <guy@alum.mit.edu> | 2003-02-24 01:22:30 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2003-02-24 01:22:30 +0000 |
commit | e345e5640e4d675c2de7b95077fa9ae3f8d07c9b (patch) | |
tree | 11e4f9c2e4d2fb3d24678348719e70d22ad98f97 /epan/tvbuff.h | |
parent | 1c159b152bf565048ea086621023612624b2901e (diff) | |
download | wireshark-e345e5640e4d675c2de7b95077fa9ae3f8d07c9b.tar.gz |
Rename "fake_unicode()" to "tvb_fake_unicode()" as it works on a tvbuff,
give it a byte-order argument, and move it to "epan/tvbuff.c".
Use it to handle UCS-2 strings in version 1 of the Service Location
Protocol. In SRVLOC V1, use registered fields that are already there
for SRVLOC V2, and add some as needed. Fix some field names.
svn path=/trunk/; revision=7186
Diffstat (limited to 'epan/tvbuff.h')
-rw-r--r-- | epan/tvbuff.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/epan/tvbuff.h b/epan/tvbuff.h index 1283692d44..1f1fc31201 100644 --- a/epan/tvbuff.h +++ b/epan/tvbuff.h @@ -9,7 +9,7 @@ * the data of a backing tvbuff, or can be a composite of * other tvbuffs. * - * $Id: tvbuff.h,v 1.29 2002/08/28 20:40:45 jmayer Exp $ + * $Id: tvbuff.h,v 1.30 2003/02/24 01:22:30 guy Exp $ * * Copyright (c) 2000 by Gilbert Ramirez <gram@alumni.rice.edu> * @@ -306,6 +306,13 @@ extern guint tvb_strsize(tvbuff_t *tvb, gint offset); * Returns -1 if 'maxlength' reached before finding EOS. */ extern gint tvb_strnlen(tvbuff_t*, gint offset, guint maxlength); +/* Convert a string from Unicode to ASCII. At the moment we fake it by + * assuming all characters are ASCII )-: The caller must free the + * result returned. The len parameter is the number of guint16's to + * convert from Unicode. */ +extern char *tvb_fake_unicode(tvbuff_t *tvb, int offset, int len, + gboolean little_endian); + /* * Format the data in the tvb from offset for size ... */ |