Title: [236099] trunk/Source/WebKitLegacy/win
- Revision
- 236099
- Author
- [email protected]
- Date
- 2018-09-17 19:54:37 -0700 (Mon, 17 Sep 2018)
Log Message
[Win][Clang][WebKitLegacy] error: cannot pass object of non-trivial type through variadic function
https://bugs.webkit.org/show_bug.cgi?id=189612
Reviewed by Alex Christensen.
Non-trivial types can't be used as aruguments of LOG_ERROR and
ASSERT_WITH_MESSAGE.
* DefaultPolicyDelegate.cpp:
(DefaultPolicyDelegate::unableToImplementPolicyWithError): Apply
static_cast<BSTR> to convert BString.
* WebLocalizableStrings.cpp:
(copyLocalizedStringFromBundle): Convert 'key' from WTF::String to
char* by using 'key.utf8().data()'.
Modified Paths
Diff
Modified: trunk/Source/WebKitLegacy/win/ChangeLog (236098 => 236099)
--- trunk/Source/WebKitLegacy/win/ChangeLog 2018-09-18 01:42:35 UTC (rev 236098)
+++ trunk/Source/WebKitLegacy/win/ChangeLog 2018-09-18 02:54:37 UTC (rev 236099)
@@ -1,3 +1,20 @@
+2018-09-17 Fujii Hironori <[email protected]>
+
+ [Win][Clang][WebKitLegacy] error: cannot pass object of non-trivial type through variadic function
+ https://bugs.webkit.org/show_bug.cgi?id=189612
+
+ Reviewed by Alex Christensen.
+
+ Non-trivial types can't be used as aruguments of LOG_ERROR and
+ ASSERT_WITH_MESSAGE.
+
+ * DefaultPolicyDelegate.cpp:
+ (DefaultPolicyDelegate::unableToImplementPolicyWithError): Apply
+ static_cast<BSTR> to convert BString.
+ * WebLocalizableStrings.cpp:
+ (copyLocalizedStringFromBundle): Convert 'key' from WTF::String to
+ char* by using 'key.utf8().data()'.
+
2018-09-13 Ryan Haddad <[email protected]>
Unreviewed, rolling out r235953.
Modified: trunk/Source/WebKitLegacy/win/DefaultPolicyDelegate.cpp (236098 => 236099)
--- trunk/Source/WebKitLegacy/win/DefaultPolicyDelegate.cpp 2018-09-18 01:42:35 UTC (rev 236098)
+++ trunk/Source/WebKitLegacy/win/DefaultPolicyDelegate.cpp 2018-09-18 02:54:37 UTC (rev 236099)
@@ -179,7 +179,7 @@
BString frameName;
frame->name(&frameName);
- LOG_ERROR("called unableToImplementPolicyWithError:%S inFrame:%S", errorStr ? errorStr : TEXT(""), frameName ? frameName : TEXT(""));
+ LOG_ERROR("called unableToImplementPolicyWithError:%S inFrame:%S", errorStr ? static_cast<BSTR>(errorStr) : TEXT(""), frameName ? static_cast<BSTR>(frameName) : TEXT(""));
return S_OK;
}
Modified: trunk/Source/WebKitLegacy/win/WebLocalizableStrings.cpp (236098 => 236099)
--- trunk/Source/WebKitLegacy/win/WebLocalizableStrings.cpp 2018-09-18 01:42:35 UTC (rev 236098)
+++ trunk/Source/WebKitLegacy/win/WebLocalizableStrings.cpp 2018-09-18 02:54:37 UTC (rev 236099)
@@ -161,7 +161,7 @@
CFStringRef result = CFCopyLocalizedStringWithDefaultValue(key.createCFString().get(), 0, bundle, notFound, 0);
- ASSERT_WITH_MESSAGE(result != notFound, "could not find localizable string %s in bundle", key);
+ ASSERT_WITH_MESSAGE(result != notFound, "could not find localizable string %s in bundle", key.utf8().data());
return result;
}
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes