From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20346 invoked by alias); 28 Sep 2005 12:22:24 -0000 Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org Received: (qmail 20240 invoked by uid 22791); 28 Sep 2005 12:22:14 -0000 Received: from exprod6og5.obsmtp.com (HELO psmtp.com) (64.18.1.125) by sourceware.org (qpsmtpd/0.30-dev) with SMTP; Wed, 28 Sep 2005 12:22:14 +0000 Received: from source ([192.150.11.134]) by exprod6ob5.obsmtp.com ([64.18.5.12]) with SMTP; Wed, 28 Sep 2005 05:22:11 PDT Received: from inner-relay-1.corp.adobe.com ([153.32.1.51]) by outbound-smtp-1.corp.adobe.com (8.12.10/8.12.10) with ESMTP id j8SCF0BM023186; Wed, 28 Sep 2005 05:15:00 -0700 (PDT) Received: from fe2.corp.adobe.com (fe2.corp.adobe.com [10.8.192.72]) by inner-relay-1.corp.adobe.com (8.12.10/8.12.10) with ESMTP id j8SCMAn2004428; Wed, 28 Sep 2005 05:22:10 -0700 (PDT) Received: from namail3.corp.adobe.com ([10.8.192.66]) by fe2.corp.adobe.com with Microsoft SMTPSVC(6.0.3790.211); Wed, 28 Sep 2005 05:22:10 -0700 Received: from 153.32.12.150 ([153.32.12.150]) by namail3.corp.adobe.com ([10.8.192.66]) via Exchange Front-End Server namailhost.corp.adobe.com ([10.8.192.72]) with Microsoft Exchange Server HTTP-DAV ; Wed, 28 Sep 2005 12:22:10 +0000 User-Agent: Microsoft-Entourage/11.2.0.050811 Date: Wed, 28 Sep 2005 12:22:00 -0000 Subject: Re: ostrstream problem From: John Love-Jensen To: , MSX to GCC Message-ID: In-Reply-To: <1127876423.25951.19.camel@localhost.localdomain> Mime-version: 1.0 Content-type: text/plain; charset="US-ASCII" Content-transfer-encoding: 7bit X-SW-Source: 2005-09/txt/msg00198.txt.bz2 Hi Ernest, I second what Peter said. Plus.... You should be aware in switching from ostrstream to std::ostringstream... std::ostringstream does the memory management for you. You don't need to trouble yourself with ostrstream's memory management burden. That alone is worth switching instead of trying to use the obsolete ostrstream! std::ostringstream's backing store is a std::string, so you don't need the ends terminator. Sincerely, --Eljay