Re: Ethereal 0.99.0 epan/strutil.c - utf_8to16 bug

Gerald Combs <[email protected]>
Newsgroups gmane.network.ethereal.devel
Message-ID <[email protected]>
[email protected] wrote:
> Ulf,
> 
> The string passed to the function is:
> 
> "C:\Program Files\Ethereal\dumpcap" -i \Device\NPF_{66E7710E-054E-408F-91A2-29B8AD1BDEDB} -Z -B 1 -f "ether host 00:14:22:CD:FD:42"
> 
> The string length exceeds INITIAL_FMTBUF_SIZE, so the
> g_realloc logic triggers.  However, the buffer is half
> the size it should be because it doesn't account for
> the size of wchar_t, resulting in the access violation.
> 
> Ironically, the call to g_malloc before this is correct:
> 
>    utf16buf[idx] = g_malloc(utf16buf_len[idx] * sizeof(wchar_t));
> 
> So the failure only occurs if the length of utf8str
> exceeds INITIAL_FMTBUF_SIZE.

Can you try build 18017 or later from
http://www.ethereal.com/distribution/buildbot-builds/win32/ and see if
the problem is fixed?
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.