From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kay Sievers Date: Wed, 03 Mar 2004 01:59:21 +0000 Subject: Re: %c option does not handle LF as a seperator Message-Id: <20040303015921.GA12710@vrfy.org> MIME-Version: 1 Content-Type: multipart/mixed; boundary="C7zPtVaVf+AK4Oqc" List-Id: References: <2F75A5CCEF1E6A4C8CA2E75CF7F529E902036598@orsmsx409.jf.intel.com> In-Reply-To: <2F75A5CCEF1E6A4C8CA2E75CF7F529E902036598@orsmsx409.jf.intel.com> To: linux-hotplug@vger.kernel.org --C7zPtVaVf+AK4Oqc Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Tue, Mar 02, 2004 at 05:06:53PM -0800, Sabharwal, Atul wrote: > but I Am not sure by just adding LF to the list of seperators would fix it. Seems so, it works for me. You may try it if you like: BUS="scsi", PROGRAM="/sbin/scsi_id", RESULT="SSEAGATE ST318436LW*3BM07NKA000070456Z6B", NAME="disk-sda-%c{3}" thanks, Kay --C7zPtVaVf+AK4Oqc Content-Type: text/plain; charset=us-ascii Content-Disposition: inline; filename="01-multiline-result.patch" ===== namedev.c 1.121 vs edited ===== --- 1.121/namedev.c Tue Mar 2 01:02:05 2004 +++ edited/namedev.c Wed Mar 3 02:35:03 2004 @@ -282,7 +282,7 @@ pos2 = temp1; while (i) { i--; - pos3 = strsep(&pos2, " "); + pos3 = strsep(&pos2, " \n\r"); if (pos3 == NULL) { dbg("requested part of result string not found"); break; --C7zPtVaVf+AK4Oqc-- ------------------------------------------------------- SF.Net is sponsored by: Speed Start Your Linux Apps Now. Build and deploy apps & Web services for Linux with a free DVD software kit from IBM. Click Now! http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel