Change contentType XSD to be compatible with both MSXML6 and xerces.
Further improve logging to aid in debugging.
This commit is contained in:
Родитель
7ced63f393
Коммит
3d9d2ac507
|
@ -48,7 +48,7 @@
|
|||
<!--
|
||||
<xs:pattern value="[media-type]"/>
|
||||
-->
|
||||
<xs:pattern value="(((([\p{IsBasicLatin}-[\p{Cc}\(\)<>@,;:\\"/\[\]\?=\{\}\s\t]])+))/((([\p{IsBasicLatin}-[\p{Cc}\(\)<>@,;:\\"/\[\]\?=\{\}\s\t]])+))((\s+)*;(\s+)*(((([\p{IsBasicLatin}-[\p{Cc}\(\)<>@,;:\\"/\[\]\?=\{\}\s\t]])+))=((([\p{IsBasicLatin}-[\p{Cc}\(\)<>@,;:\\"/\[\]\?=\{\}\s\t]])+)|("(([\p{IsLatin-1Supplement}\p{IsBasicLatin}-[\p{Cc}"\n\r]]|(\s+))|(\\[\p{IsBasicLatin}]))*"))))*)" />
|
||||
<xs:pattern value="(([!$&'\(\)\*\+,:=]|(%[0-9a-fA-F][0-9a-fA-F])|[:@]|[a-zA-Z0-9\-_~])+)/(([!$&'\(\)\*\+,:=]|(%[0-9a-fA-F][0-9a-fA-F])|[:@]|\.|[a-zA-Z0-9\-_~])+)" />
|
||||
</xs:restriction>
|
||||
</xs:simpleType>
|
||||
|
||||
|
|
|
@ -211,22 +211,26 @@ namespace MSIX {
|
|||
}
|
||||
|
||||
// Helper to make code more terse and more readable at the same time.
|
||||
#define ThrowErrorIfNot(c, a, m) \
|
||||
{ \
|
||||
if (!(a)) \
|
||||
{ \
|
||||
assert(false); \
|
||||
throw MSIX::Exception(c,m); \
|
||||
} \
|
||||
#define ThrowErrorIfNot(c, a, m) \
|
||||
{ \
|
||||
if (!(a)) \
|
||||
{ assert(false); \
|
||||
std::ostringstream _message; \
|
||||
_message << "Call failed in: " << __FILE__ << " on line " << __LINE__ << "\n" << m; \
|
||||
std::string reason = _message.str(); \
|
||||
throw MSIX::Exception(c, reason.c_str()); \
|
||||
} \
|
||||
}
|
||||
|
||||
#define ThrowWin32ErrorIfNot(c, a, m) \
|
||||
{ \
|
||||
if (!(a)) \
|
||||
{ \
|
||||
assert(false); \
|
||||
throw MSIX::Win32Exception(c,m); \
|
||||
} \
|
||||
#define ThrowWin32ErrorIfNot(c, a, m) \
|
||||
{ \
|
||||
if (!(a)) \
|
||||
{ assert(false); \
|
||||
std::ostringstream _message; \
|
||||
_message << "Call failed in: " << __FILE__ << " on line " << __LINE__ << "\n" << m; \
|
||||
std::string reason = _message.str(); \
|
||||
throw MSIX::Win32Exception(c,reason.c_str()); \
|
||||
} \
|
||||
}
|
||||
|
||||
#define ThrowErrorIf(c, a, m) ThrowErrorIfNot(c,!(a), m)
|
||||
|
|
Загрузка…
Ссылка в новой задаче