# HG changeset patch # User Daniel Stodden # Date 1276140311 25200 # Node ID bbdfc4c5a31e26d23411a83edbef4a55ff904f2d # Parent 28af9eb507f2c315e53bb72c03399c7e69062787 blktap2: Fix broken tap-ctl-list type/path filter logic. Signed-off-by: Daniel Stodden diff -r 28af9eb507f2 -r bbdfc4c5a31e tools/blktap2/control/tap-ctl.c --- a/tools/blktap2/control/tap-ctl.c Wed Jun 09 07:55:19 2010 +0100 +++ b/tools/blktap2/control/tap-ctl.c Wed Jun 09 20:25:11 2010 -0700 @@ -147,10 +147,10 @@ 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)