xbps-uchroot: assert that strdup() does not fail.

This commit is contained in:
Juan RP 2015-05-06 11:38:06 +02:00
parent 7d6d1805f3
commit 4a97810c0b

View File

@ -152,6 +152,7 @@ add_bindmount(char *bm)
size_t len; size_t len;
src = strdup(bm); src = strdup(bm);
assert(src);
dest = strchr(bm, ':'); dest = strchr(bm, ':');
if (dest == NULL || *dest == '\0') { if (dest == NULL || *dest == '\0') {
errno = EINVAL; errno = EINVAL;