This is the mail archive of the
cygwin-patches
mailing list for the Cygwin project.
Re: ptsname_r
- From: Christopher Faylor <cgf-use-the-mailinglist-please at cygwin dot com>
- To: cygwin-patches at cygwin dot com
- Date: Tue, 8 Nov 2011 01:04:18 -0500
- Subject: Re: ptsname_r
- References: <4EB82DF9.7080408@redhat.com> <20111107193521.GA30056@ednor.casa.cgf.cx> <4EB8437B.5090600@redhat.com> <4EB843B4.4030605@redhat.com> <4EB846BC.9010003@redhat.com>
- Reply-to: cygwin-patches at cygwin dot com
On Mon, Nov 07, 2011 at 01:59:40PM -0700, Eric Blake wrote:
>On 11/07/2011 01:46 PM, Eric Blake wrote:
>>> Thanks. Also, even with your patches of today, ptsname() is still not
>>> thread-safe; should we be sticking that in a thread-local buffer rather
>>> than in static storage, similar to how other functions like strerror()
>>> are thread-safe?
>
>I didn't tackle that,
>
>>
>> Also, should we have an efault handler in syscalls.cc ptsname_r(),
>> similar to ttyname_r(), so as to gracefully reject invalid buffers
>> rather than faulting?
>
>but I had this additional code in my sandbox right before your commit
>hit CVS; should I add a ChangeLog and make it a formal patch submission?
No thanks. Except for the Copyright change in stdlib.h, there is nothing that
I think should go in. On inspection, openpty() needs some work.
cgf