X-Git-Url: https://wimlib.net/git/?p=wimlib;a=blobdiff_plain;f=src%2Fdentry.c;h=862c6640c9bb54b9bef52610824604091b830e13;hp=aa626764565386f228620beab0a36b67f1bc3d65;hb=5f3757249c17cb9e2826f645e0f8618534c80fcc;hpb=3071e89c11d1be71cf45b694432e5908e0c4ded9 diff --git a/src/dentry.c b/src/dentry.c index aa626764..862c6640 100644 --- a/src/dentry.c +++ b/src/dentry.c @@ -64,6 +64,7 @@ #include "wimlib/encoding.h" #include "wimlib/endianness.h" #include "wimlib/metadata.h" +#include "wimlib/paths.h" #include @@ -1341,8 +1342,7 @@ read_dentry(const u8 * restrict buf, size_t buf_len, /* Read the filename if present. Note: if the filename is empty, there * is no null terminator following it. */ if (file_name_nbytes) { - dentry->file_name = utf16le_dupz((const utf16lechar *)p, - file_name_nbytes); + dentry->file_name = utf16le_dupz(p, file_name_nbytes); if (dentry->file_name == NULL) { ret = WIMLIB_ERR_NOMEM; goto err_free_dentry; @@ -1354,8 +1354,7 @@ read_dentry(const u8 * restrict buf, size_t buf_len, /* Read the short filename if present. Note: if there is no short * filename, there is no null terminator following it. */ if (short_name_nbytes) { - dentry->short_name = utf16le_dupz((const utf16lechar *)p, - short_name_nbytes); + dentry->short_name = utf16le_dupz(p, short_name_nbytes); if (dentry->short_name == NULL) { ret = WIMLIB_ERR_NOMEM; goto err_free_dentry;