Bug 978177 - Modify PoisonIOInterposerWin functions that accept UNICODE_STRING to use nsDependentSubstring instead of nsDependentString. r=bsmedberg, a=sledru
--- a/xpcom/build/PoisonIOInterposerWin.cpp
+++ b/xpcom/build/PoisonIOInterposerWin.cpp
@@ -245,17 +245,17 @@ static NTSTATUS NTAPI InterposedNtCreate
{
// Report IO
char16_t* buf = aObjectAttributes ?
aObjectAttributes->ObjectName->Buffer :
MOZ_UTF16("");
uint32_t len = aObjectAttributes ?
aObjectAttributes->ObjectName->Length / sizeof(WCHAR) :
0;
- nsDependentString filename(buf, len);
+ nsDependentSubstring filename(buf, len);
WinIOAutoObservation timer(IOInterposeObserver::OpCreateOrOpen, filename);
// Something is badly wrong if this function is undefined
MOZ_ASSERT(gOriginalNtCreateFile);
// Execute original function
return gOriginalNtCreateFile(
aFileHandle,
@@ -424,17 +424,17 @@ static NTSTATUS NTAPI InterposedNtQueryF
{
// Report IO
char16_t* buf = aObjectAttributes ?
aObjectAttributes->ObjectName->Buffer :
MOZ_UTF16("");
uint32_t len = aObjectAttributes ?
aObjectAttributes->ObjectName->Length / sizeof(WCHAR) :
0;
- nsDependentString filename(buf, len);
+ nsDependentSubstring filename(buf, len);
WinIOAutoObservation timer(IOInterposeObserver::OpStat, filename);
// Something is badly wrong if this function is undefined
MOZ_ASSERT(gOriginalNtQueryFullAttributesFile);
// Execute original function
return gOriginalNtQueryFullAttributesFile(
aObjectAttributes,