X-Git-Url: https://wimlib.net/git/?p=wimlib;a=blobdiff_plain;f=src%2Fadd_image.c;h=7dcee10b01a4a55ac2ded3dad802dd2007fe5c73;hp=caffafebd23de4935cd2bd4d84591b8dc1cc779e;hb=35f5614d21f94548119cc22b8ad0bcd3227cae10;hpb=f69ae15310f292995d2f0838c91ee61b721c356c diff --git a/src/add_image.c b/src/add_image.c index caffafeb..7dcee10b 100644 --- a/src/add_image.c +++ b/src/add_image.c @@ -77,11 +77,8 @@ wimlib_add_empty_image(WIMStruct *wim, const tchar *name, int *new_idx_ret) DEBUG("Adding empty image \"%"TS"\"", name); - if (name == NULL || name[0] == T('\0')) { - ERROR("Must specify a non-empty string for the image name"); - ret = WIMLIB_ERR_INVALID_PARAM; - goto out; - } + if (name == NULL) + name = T(""); if (wim->hdr.total_parts != 1) { ERROR("Cannot add an image to a split WIM");