aboutsummaryrefslogtreecommitdiffstats
path: root/tools/blktap2/control/tap-ctl-create.c
diff options
context:
space:
mode:
Diffstat (limited to 'tools/blktap2/control/tap-ctl-create.c')
-rw-r--r--tools/blktap2/control/tap-ctl-create.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/blktap2/control/tap-ctl-create.c b/tools/blktap2/control/tap-ctl-create.c
index 46d135e93c..f4c47f1f7d 100644
--- a/tools/blktap2/control/tap-ctl-create.c
+++ b/tools/blktap2/control/tap-ctl-create.c
@@ -44,8 +44,10 @@ tap_ctl_create(const char *params, char **devname)
return err;
id = tap_ctl_spawn();
- if (id < 0)
+ if (id < 0) {
+ err = id;
goto destroy;
+ }
err = tap_ctl_attach(id, minor);
if (err)