mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1124189 - IndexedDB Unkown Error @ ActorsParent.cpp:414 when calling indexedDB.open; r=bent
This commit is contained in:
parent
31078f1aaf
commit
5bd9082ece
@ -10,6 +10,7 @@
|
||||
#include "nsAutoPtr.h"
|
||||
#include "nsCOMPtr.h"
|
||||
#include "nsDebug.h"
|
||||
#include "nsPrintfCString.h"
|
||||
#include "nsString.h"
|
||||
#include "nsTArray.h"
|
||||
|
||||
@ -22,6 +23,13 @@
|
||||
|
||||
#define DSSTORE_FILE_NAME ".DS_Store"
|
||||
|
||||
#define QM_WARNING(...) \
|
||||
do { \
|
||||
nsPrintfCString str(__VA_ARGS__); \
|
||||
mozilla::dom::quota::ReportInternalError(__FILE__, __LINE__, str.get()); \
|
||||
NS_WARNING(str.get()); \
|
||||
} while (0)
|
||||
|
||||
BEGIN_QUOTA_NAMESPACE
|
||||
|
||||
void
|
||||
@ -33,6 +41,9 @@ AssertCurrentThreadOwnsQuotaMutex();
|
||||
bool
|
||||
IsOnIOThread();
|
||||
|
||||
void
|
||||
ReportInternalError(const char* aFile, uint32_t aLine, const char* aStr);
|
||||
|
||||
END_QUOTA_NAMESPACE
|
||||
|
||||
#endif // mozilla_dom_quota_quotacommon_h__
|
||||
|
@ -88,8 +88,6 @@
|
||||
#define MB * 1024ULL KB
|
||||
#define GB * 1024ULL MB
|
||||
|
||||
#define QM_WARNING(...) NS_WARNING(nsPrintfCString(__VA_ARGS__).get())
|
||||
|
||||
USING_QUOTA_NAMESPACE
|
||||
using namespace mozilla;
|
||||
using namespace mozilla::dom;
|
||||
@ -489,6 +487,22 @@ AssertCurrentThreadOwnsQuotaMutex()
|
||||
#endif
|
||||
}
|
||||
|
||||
void
|
||||
ReportInternalError(const char* aFile, uint32_t aLine, const char* aStr)
|
||||
{
|
||||
// Get leaf of file path
|
||||
for (const char* p = aFile; *p; ++p) {
|
||||
if (*p == '/' && *(p + 1)) {
|
||||
aFile = p + 1;
|
||||
}
|
||||
}
|
||||
|
||||
nsContentUtils::LogSimpleConsoleError(
|
||||
NS_ConvertUTF8toUTF16(nsPrintfCString(
|
||||
"Quota %s: %s:%lu", aStr, aFile, aLine)),
|
||||
"quota");
|
||||
}
|
||||
|
||||
END_QUOTA_NAMESPACE
|
||||
|
||||
namespace {
|
||||
@ -1910,9 +1924,8 @@ QuotaManager::InitializeRepository(PersistenceType aPersistenceType)
|
||||
continue;
|
||||
}
|
||||
|
||||
nsPrintfCString message("Something (%s) in the repository that doesn't "
|
||||
"belong!", NS_ConvertUTF16toUTF8(leafName).get());
|
||||
NS_WARNING(message.get());
|
||||
QM_WARNING("Something (%s) in the repository that doesn't belong!",
|
||||
NS_ConvertUTF16toUTF8(leafName).get());
|
||||
return NS_ERROR_UNEXPECTED;
|
||||
}
|
||||
|
||||
@ -4802,9 +4815,8 @@ OriginParser::Parse(uint32_t* aAppId,
|
||||
}
|
||||
|
||||
if (mError) {
|
||||
nsPrintfCString message("Origin '%s' failed to parse, handled tokens: %s",
|
||||
mOrigin.get(), mHandledTokens.get());
|
||||
NS_WARNING(message.get());
|
||||
QM_WARNING("Origin '%s' failed to parse, handled tokens: %s", mOrigin.get(),
|
||||
mHandledTokens.get());
|
||||
|
||||
return false;
|
||||
}
|
||||
@ -5059,7 +5071,7 @@ OriginParser::HandleToken(const nsDependentCSubstring& aToken)
|
||||
MOZ_ASSERT(mSchemaType == eFile);
|
||||
|
||||
if (aToken.IsEmpty()) {
|
||||
QM_WARNING("Expected a driver letter or pathname component "
|
||||
QM_WARNING("Expected a drive letter or pathname component "
|
||||
"(not an empty string)!");
|
||||
|
||||
mError = true;
|
||||
|
Loading…
Reference in New Issue
Block a user