]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
* src/storage_backend_logical.c: patch from David Lively fixing
authorDaniel Veillard <veillard@redhat.com>
Wed, 30 Jul 2008 08:52:44 +0000 (08:52 +0000)
committerDaniel Veillard <veillard@redhat.com>
Wed, 30 Jul 2008 08:52:44 +0000 (08:52 +0000)
  small differences of behaviour for 'lvs' and 'vgs' on SLES
Daniel

AUTHORS
ChangeLog
src/storage_backend_logical.c

diff --git a/AUTHORS b/AUTHORS
index 8b20d0b9f191b1773fd905f9616742d0d0ca8fed..4909b6ada72a9eaf6018e2e244e6e1d62acce1c3 100644 (file)
--- a/AUTHORS
+++ b/AUTHORS
@@ -47,6 +47,7 @@ Patches have also been contributed by:
   Kaitlin Rupert       <kaitlin@linux.vnet.ibm.com>
   Evgeniy Sokolov      <evg@openvz.org>
   John Levon           <john.levon@sun.com>
+  David Lively         <dlively@virtualiron.com>
 
   [....send patches to get your name here....]
 
index cbb7760e746640d4360a6793d3bab195ee00caba..ab4f80198c05e882229f571745e503f419fb03c2 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Wed Jul 30 10:51:12 CEST 2008 Daniel Veillard <veillard@redhat.com>
+
+       * src/storage_backend_logical.c: patch from David Lively fixing
+         small differences of behaviour for 'lvs' and 'vgs' on SLES
+
 Wed Jul 30 10:45:41 CEST 2008 Daniel Veillard <veillard@redhat.com>
 
        * qemud/qemud.c: patch from Guido Günther fixing the place where
index 9a0c27fecf1407688e4851c154bad01c9771b5ca..db9768c0e8c1001cc0c23b266dc3ae6c9913fe8f 100644 (file)
@@ -200,9 +200,11 @@ virStorageBackendLogicalFindLVs(virConnectPtr conn,
      * Pull out name & uuid, device, device extent start #, segment size, extent size.
      *
      * NB can be multiple rows per volume if they have many extents
+     *
+     * NB lvs from some distros (e.g. SLES10 SP2) outputs trailing ":" on each line
      */
     const char *regexes[] = {
-        "^\\s*(\\S+):(\\S+):(\\S+)\\((\\S+)\\):(\\S+):(\\S+)\\s*$"
+        "^\\s*(\\S+):(\\S+):(\\S+)\\((\\S+)\\):(\\S+):([0-9]+):?\\s*$"
     };
     int vars[] = {
         6
@@ -351,9 +353,11 @@ virStorageBackendLogicalRefreshPool(virConnectPtr conn,
      *    10603200512:4328521728
      *
      * Pull out size & free
+     *
+     * NB vgs from some distros (e.g. SLES10 SP2) outputs trailing ":" on each line
      */
     const char *regexes[] = {
-        "^\\s*(\\S+):(\\S+)\\s*$"
+        "^\\s*(\\S+):([0-9]+):?\\s*$"
     };
     int vars[] = {
         2