From mboxrd@z Thu Jan 1 00:00:00 1970 From: Martin Pitt Date: Wed, 21 Apr 2010 11:42:35 +0000 Subject: Re: [PATCH] remove buffer-overrun risk in readlink call Message-Id: <20100421114235.GA24032@piware.de> List-Id: References: <1271847172-12495-1-git-send-email-mathias.nyman@nokia.com> In-Reply-To: <1271847172-12495-1-git-send-email-mathias.nyman@nokia.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: linux-hotplug@vger.kernel.org Hello Mathias, Mathias Nyman [2010-04-21 13:52 +0300]: > readlink does not write a nul character to the end of the > string it returns. Therefore ask for one fewer character > than the buffer size so there's always room for an extra \0. Nice catch, thanks! Pushed. Martin -- Martin Pitt | http://www.piware.de Ubuntu Developer (www.ubuntu.com) | Debian Developer (www.debian.org)