>>> Joerg Sonnenberger <jo...@britannica.bec.de> wrote > On Thu, Feb 20, 2014 at 08:41:36PM +0900, Takeshi Nakayama wrote: > > >>> "Joerg Sonnenberger" <jo...@netbsd.org> wrote > > > > > Module Name: src > > > Committed By: joerg > > > Date: Thu Feb 20 11:08:57 UTC 2014 > > > > > > Modified Files: > > > src/sys/netsmb: iconv.c > > > > > > Log Message: > > > Don't dereference NULL pointers. > > > > I guess proper fix is to move NULL check in iconv_conv(). > > The issue was not so much the inbuf check, but that inbytesleft is a > NULL pointer. That said, I don't understand what the first call was > supposed to do.
iconv_conv() is a function correspond to iconv(3), so the first call intends to initialize the internal state. But iconv_open() and iconv_close() are competely dummy functions, so it does nothing for now. -- Takeshi Nakayama