From 4a97810c0bac446b3f7486cb3bc2c05fcb404531 Mon Sep 17 00:00:00 2001 From: Juan RP Date: Wed, 6 May 2015 11:38:06 +0200 Subject: [PATCH] xbps-uchroot: assert that strdup() does not fail. --- bin/xbps-uchroot/main.c | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/xbps-uchroot/main.c b/bin/xbps-uchroot/main.c index f9e1f12b..fa2a6570 100644 --- a/bin/xbps-uchroot/main.c +++ b/bin/xbps-uchroot/main.c @@ -152,6 +152,7 @@ add_bindmount(char *bm) size_t len; src = strdup(bm); + assert(src); dest = strchr(bm, ':'); if (dest == NULL || *dest == '\0') { errno = EINVAL;