open_subarray returns valid fd to a container. In case of error shall return negative value. Signed-off-by: Marcin Labun <marcin.labun@xxxxxxxxx> --- util.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/util.c b/util.c index ce03239..1680d6b 100644 --- a/util.c +++ b/util.c @@ -1370,7 +1370,7 @@ int open_subarray(char *dev, char *subarray, struct supertype *st, int quiet) if (!quiet) fprintf(stderr, Name ": Couldn't open %s, aborting\n", dev); - return 2; + return -2; } st->devnum = fd2devnum(fd); -- 1.6.4.2 -- To unsubscribe from this list: send the line "unsubscribe linux-raid" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html