tchar *tstr;
size_t tstr_nbytes;
utf16lechar *ucs = va_arg(va, utf16lechar*);
- size_t ucs_nbytes = utf16le_strlen(ucs);
- ret = utf16le_to_tstr(ucs, ucs_nbytes,
- &tstr, &tstr_nbytes);
- if (ret) {
- ret = tfprintf(fp, T("??????"));
+ if (ucs) {
+ size_t ucs_nbytes = utf16le_strlen(ucs);
+
+ ret = utf16le_to_tstr(ucs, ucs_nbytes,
+ &tstr, &tstr_nbytes);
+ if (ret) {
+ ret = tfprintf(fp, T("??????"));
+ } else {
+ ret = tfprintf(fp, T("%"TS), tstr);
+ FREE(tstr);
+ }
+ if (ret < 0)
+ return -1;
+ else
+ n += ret;
} else {
- ret = tfprintf(fp, T("%"TS), tstr);
- FREE(tstr);
+ n += tfprintf(fp, T("(null)"));
}
- if (ret < 0)
- return -1;
- else
- n += ret;
p++;
} else {
if (tputc(*p, fp) == EOF)
tfprintf(stderr, T(": %"TS), buf);
}
tputc(T('\n'), stderr);
+ fflush(stderr);
errno = errno_save;
#ifndef DEBUG
}
va_list va;
va_start(va, format);
- wimlib_vmsg(T("[ERROR] "), format, va, false);
+ wimlib_vmsg(T("\r[ERROR] "), format, va, false);
va_end(va);
}
va_list va;
va_start(va, format);
- wimlib_vmsg(T("[ERROR] "), format, va, true);
+ wimlib_vmsg(T("\r[ERROR] "), format, va, true);
va_end(va);
}
va_list va;
va_start(va, format);
- wimlib_vmsg(T("[WARNING] "), format, va, false);
+ wimlib_vmsg(T("\r[WARNING] "), format, va, false);
va_end(va);
}
va_list va;
va_start(va, format);
- wimlib_vmsg(T("[WARNING] "), format, va, true);
+ wimlib_vmsg(T("\r[WARNING] "), format, va, true);
va_end(va);
}
void wimlib_debug(const tchar *file, int line, const char *func,
const tchar *format, ...)
{
-
va_list va;
tchar buf[tstrlen(file) + strlen(func) + 30];
[WIMLIB_ERR_IMAGE_COUNT]
= T("Inconsistent image count among the metadata "
"resources, the WIM header, and/or the XML data"),
+ [WIMLIB_ERR_INSUFFICIENT_PRIVILEGES_TO_EXTRACT]
+ = T("User does not have sufficient privileges to correctly extract the data"),
[WIMLIB_ERR_IMAGE_NAME_COLLISION]
= T("Tried to add an image with a name that is already in use"),
[WIMLIB_ERR_INTEGRITY]
= T("An invalid parameter was given"),
[WIMLIB_ERR_INVALID_PART_NUMBER]
= T("The part number or total parts of the WIM is invalid"),
+ [WIMLIB_ERR_INVALID_REPARSE_DATA]
+ = T("The reparse data of a reparse point was invalid"),
[WIMLIB_ERR_INVALID_RESOURCE_HASH]
= T("The SHA1 message digest of a WIM resource did not match the expected value"),
[WIMLIB_ERR_INVALID_RESOURCE_SIZE]
= T("Could not rename a file"),
[WIMLIB_ERR_REOPEN]
= T("Could not re-open the WIM after overwriting it"),
+ [WIMLIB_ERR_REPARSE_POINT_FIXUP_FAILED]
+ = T("Unable to complete reparse point fixup"),
[WIMLIB_ERR_RESOURCE_ORDER]
= T("The components of the WIM were arranged in an unexpected order"),
[WIMLIB_ERR_SPECIAL_FILE]