[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen-unstable] blktap2: Fix broken tap-ctl-list type/path filter logic



# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1276154755 -3600
# Node ID a34358c64b63c803fcf51c8b31718946d172eccd
# Parent  07d09ceb291aecea3f8d4bfd3a9bfc213f7f8b9e
blktap2: Fix broken tap-ctl-list type/path filter logic

Signed-off-by: Daniel Stodden <daniel.stodden@xxxxxxxxxx>
---
 tools/blktap2/control/tap-ctl.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff -r 07d09ceb291a -r a34358c64b63 tools/blktap2/control/tap-ctl.c
--- a/tools/blktap2/control/tap-ctl.c   Thu Jun 10 08:25:10 2010 +0100
+++ b/tools/blktap2/control/tap-ctl.c   Thu Jun 10 08:25:55 2010 +0100
@@ -147,10 +147,10 @@ tap_cli_list(int argc, char **argv)
                if (pid >= 0 && entry->pid != pid)
                        continue;
 
-               if (type && entry->type && strcmp(entry->type, type))
+               if (type && (!entry->type || strcmp(entry->type, type)))
                        continue;
 
-               if (file && entry->path && strcmp(entry->path, file))
+               if (file && (!entry->path || strcmp(entry->path, file)))
                        continue;
 
                if (tty)

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


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.