Re: mmap-related memory leak using iconv_open/close?

From: Andrei Voropaev (avorop_at_mail.ru)
Date: 09/10/04

  • Next message: Pascal Bourguignon: "Re: Would this group be the right group to ask these Unix/Linux questions?"
    Date: 10 Sep 2004 07:20:56 GMT
    
    

    On 2004-09-10, Chris Markle <cmarkle@sendmail.com> wrote:
    > Folks,
    >
    > (OS is HP-UX 11.11) We're seeing a growth in mmap'd memory over time when
    > using iconv_open (maybe iconv_close). Below is an analysis from one of our
    > programmers... Anyone have any familiarity with this sort of issue?
    >
    > Chris
    >
    >> After analysing the iconv calls from xxx I wrote a
    >> small programm that just made those calls -- it leaked --
    >> and then narrowed it down to a simple loop.
    >>
    >> If this guy here:
    >>
    >> #include <iconv.h>
    >>
    >> int
    >> main(void)
    >> {
    >> for (;;)
    >> {
    >> iconv_t c = iconv_open("eucJP", "jis");
    >> iconv_close(c);
    >> }
    >> }
    >>
    >> runs long enough, one can see its MMAP consumption go up
    >> in procsize -p, without about a minute between increments
    >> (on qa-stills.)
    >>
    >> (The charsets aren't really important, as far as I can
    >> tell; conversion from "utf8" to "eucJP" works, too.)

    This program does not create any problems on Linux with glibc-2.3.2

    Andrei


  • Next message: Pascal Bourguignon: "Re: Would this group be the right group to ask these Unix/Linux questions?"