From 707401fc1e697362cdaadcfaac4edc964b80b1a0 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Tue, 11 Apr 2000 13:47:17 +0000 Subject: added a cheap and nasty skip_unibuf() fn to allow easier merging from TNG out unicode string handling functions need a lot of work --- source/lib/util_unistr.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/source/lib/util_unistr.c b/source/lib/util_unistr.c index 6983d1100a6..8a02878c135 100644 --- a/source/lib/util_unistr.c +++ b/source/lib/util_unistr.c @@ -137,6 +137,16 @@ void unistr_to_ascii(char *dest, const uint16 *src, int len) *dest = 0; } +/* from TNG - should be fixed */ +char *skip_unibuf(char *src, int len) +{ + char *srcend = src + len; + + while (src < srcend && SVAL(src,0)) src += 2; + + return src; +} + /******************************************************************* Skip past some unicode strings in a buffer. -- cgit