From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bernd Petrovitsch Subject: Re: [PATCH] ACPI: replace strlen("string") with sizeof("string") -1 Date: Tue, 07 Aug 2012 15:19:47 +0200 Message-ID: <1344345590.3975.1.camel@thorin> References: <50201156.30704@pavlinux.ru> <5A9BC72FD5CEC94EA024CED8E31D701A2FD84FC0@wdscexmb03.sc.wdc.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <5A9BC72FD5CEC94EA024CED8E31D701A2FD84FC0@wdscexmb03.sc.wdc.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linux-pm-bounces@lists.linux-foundation.org Errors-To: linux-pm-bounces@lists.linux-foundation.org To: Daniel Taylor Cc: Len Brown , "linux-kernel@vger.kernel.org" , "linux-acpi@vger.kernel.org" , Pavel Vasilyev , "linux-pm@lists.linux-foundation.org" List-Id: linux-acpi@vger.kernel.org On Mon, 2012-08-06 at 22:57 +0000, Daniel Taylor wrote: > Silly question: when did sizeof("string") get changed to be anything > other than the size of the pointer ("string" is, after all, an array > of characters)? It is since K&R times that way. If you do not know the difference between a pointer and an array (and these are vastly different), go learn something new about C. Bernd -- Bernd Petrovitsch Email : bernd@petrovitsch.priv.at LUGA : http://www.luga.at