WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] [PATCH] fix udevinfo version string parsing

To: xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-devel] [PATCH] fix udevinfo version string parsing
From: Muli Ben-Yehuda <mulix@xxxxxxxxx>
Date: Thu, 24 Nov 2005 21:19:02 +0200
Cc: ladypine@xxxxxxxxxxxx, Ewan Mellor <ewan@xxxxxxxxxxxxx>
Delivery-date: Thu, 24 Nov 2005 19:19:05 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.11
check_hotplug fails on one of my machines running ubunto 4.10 "Warty
Warhog", due to misparsing the udevinfo version string. The problem is
caused by an old version of sed that does not appreciate the
regexp. This patch fixes it, and also works on debian unstable and
SLES9SP2. Please apply...

Signed-Off-By: Muli Ben-Yehuda <mulix@xxxxxxxxx>
Signed-Off-By: Orna Agmon <ladypine@xxxxxxxxxxxx>

diff -r dca4893b0b9f14a99ea46abcadcefc3246707585 -r 
962bf38a5c6f7ffdb5f9fea0265cb7b1659c6d5c install.sh
--- a/install.sh        Thu Nov 24 14:08:27 2005
+++ b/install.sh        Thu Nov 24 19:16:40 2005
@@ -28,7 +28,7 @@
 echo "All done."
 
 [ -x "$(which udevinfo)" ] && \
-  UDEV_VERSION=$(udevinfo -V | sed -e 's/^.*\s\([0-9]\+\)[^0-9]*/\1/')
+  UDEV_VERSION=$(udevinfo -V | sed -e 's/^[^0-9]* 
\([0-9]\{1,\}\)[^0-9]\{0,\}/\1/')
 
 if [ -n "$UDEV_VERSION" ] && [ $UDEV_VERSION -ge 059 ]; then
   cp -f $src/etc/udev/rules.d/*.rules $dst/etc/udev/rules.d/
diff -r dca4893b0b9f14a99ea46abcadcefc3246707585 -r 
962bf38a5c6f7ffdb5f9fea0265cb7b1659c6d5c tools/check/check_hotplug
--- a/tools/check/check_hotplug Thu Nov 24 14:08:27 2005
+++ b/tools/check/check_hotplug Thu Nov 24 19:16:40 2005
@@ -7,7 +7,7 @@
    exit 1
 }
 [ -x "$(which udevinfo)" ] && \
-  UDEV_VERSION=$(udevinfo -V | sed -e 's/^.*\s\([0-9]\+\)[^0-9]*/\1/')
+  UDEV_VERSION=$(udevinfo -V | sed -e 's/^[^0-9]* 
\([0-9]\{1,\}\)[^0-9]\{0,\}/\1/')
 
 if [ -n "$UDEV_VERSION" ] && [ $UDEV_VERSION -ge 059 ]; then
   exit 0

-- 
Muli Ben-Yehuda
http://www.mulix.org | http://mulix.livejournal.com/


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>