From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 82497 invoked by alias); 2 Jun 2017 10:04:18 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Received: (qmail 82476 invoked by uid 89); 2 Jun 2017 10:04:18 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.9 required=5.0 tests=BAYES_00,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,RP_MATCHES_RCVD,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=Hx-spam-relays-external:sk:dhcp-19, H*r:sk:dhcp-19, H*RU:sk:dhcp-19 X-HELO: mx1.redhat.com DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com D0D473DE3D Authentication-Results: ext-mx05.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx05.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=fweimer@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com D0D473DE3D Subject: Re: [PATCH] Dynamic growable arrays for internal use To: Carlos O'Donell Cc: GNU C Library References: From: Florian Weimer Message-ID: Date: Fri, 02 Jun 2017 10:04:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.1.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-SW-Source: 2017-06/txt/msg00082.txt.bz2 On 06/02/2017 09:37 AM, Carlos O'Donell wrote: > In summary the remaining points look like this: > > * Add rationale to malloc/dynarray.h as a comment explaining when and > why you would use it instead of a scratch buffer. What you write below > with some adjustments is good. Okay, I added comments to dynarray.h. >> diff --git a/support/capture_subprocess.h b/support/capture_subprocess.h >> new file mode 100644 >> index 0000000..3265d63 >> --- /dev/null >> +++ b/support/capture_subprocess.h >> +/* Invoke CALLBACK (CLOSURE) in a subprocess and capture standard >> + output, standard error, and the exit status. The out.buffer and >> + err.buffer members in the result are null-terminated strings which >> + can be examined by te caller. (out.out and err.out are NULL.) */ > > s/te/the/g. > > Suggest: > can be examined by the caller (out.out and err.out are NULL). Thanks, fixed. >> + >> +#include >> diff --git a/support/xdup2.c b/support/xdup2.c >> new file mode 100644 >> index 0000000..f4a3759 >> --- /dev/null >> +++ b/support/xdup2.c >> @@ -0,0 +1,28 @@ >> +/* pipe with error checking. > > s/pipe/dup2/g Fixed. I adjusted the patch to the presence of check_mul_overflow_size_t in and committed it. Florian