From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/4218 Path: news.gmane.org!not-for-mail From: Laurent Bercot Newsgroups: gmane.linux.lib.musl.general Subject: Re: request: increase TTY_NAME_MAX in limits.h Date: Sat, 09 Nov 2013 17:20:35 +0000 Message-ID: <527E6EE3.2050109@skarnet.org> References: <527E1774.4060305@skarnet.org> <20131109163603.GG24286@brightrain.aerifal.cx> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1384017642 27440 80.91.229.3 (9 Nov 2013 17:20:42 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 9 Nov 2013 17:20:42 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-4222-gllmg-musl=m.gmane.org@lists.openwall.com Sat Nov 09 18:20:46 2013 Return-path: Envelope-to: gllmg-musl@plane.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by plane.gmane.org with smtp (Exim 4.69) (envelope-from ) id 1VfCDG-0000G0-Bc for gllmg-musl@plane.gmane.org; Sat, 09 Nov 2013 18:20:46 +0100 Original-Received: (qmail 5783 invoked by uid 550); 9 Nov 2013 17:20:45 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Original-Received: (qmail 5774 invoked from network); 9 Nov 2013 17:20:45 -0000 X-SourceIP: 89.100.252.69 User-Agent: Mozilla/5.0 (Windows NT 6.2; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.1.0 In-Reply-To: <20131109163603.GG24286@brightrain.aerifal.cx> Xref: news.gmane.org gmane.linux.lib.musl.general:4218 Archived-At: > If we change it I think we might as well go with the glibc value of 32 > rather than just increasing it by 4. That would be great, thanks :) I'm honestly surprised that those buffers are so small, even in glibc. Sure, it takes up static space, and in practice a small value works for most people since it will usually be /dev/something, but since ttyname() is not supposed to ever fail with ERANGE or any kind of overflow, I was expecting the buffer to be PATH_MAX bytes. Or even dynamically (re)allocated - which would pull in malloc(), but text space + a bit of heap space is cheaper than static space. -- Laurent