Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT sources DOT redhat DOT com Delivered-To: mailing list cygwin AT sources DOT redhat DOT com X-Envelope-Sender-Is: Andrej DOT Borsenkow AT mow DOT siemens DOT ru (at relayer goliath.siemens.de) From: "Andrej Borsenkow" To: Subject: memory leak in setenv()? Date: Tue, 25 Jul 2000 12:30:05 +0400 Message-ID: <001201bff612$88df19f0$21c9ca95@mow.siemens.ru> MIME-Version: 1.0 Content-Type: text/plain; charset="koi8-r" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2911.0) X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400 Importance: Normal If existing value is longer than new, old value is simply overwritten. But if old value is shorter, new memory chunk is allocated via malloc(), but old one is never freed. Initially all environment strings are allocated using strdup() in environ_init(), so who is responsible for freeing unused memory in this case? Do I miss something here? -andrej Have a nice DOS! B >> -- Want to unsubscribe from this list? Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com