mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1168593 - Make AutoStableStringChars::init use MOZ_WARN_UNUSED_RESULT. r=jandem
This commit is contained in:
parent
2facd36063
commit
e4610dcf14
@ -590,7 +590,10 @@ AutoEntryScript::DocshellEntryMonitor::Entry(JSContext* aCx, JSFunction* aFuncti
|
||||
if (rootedFunction) {
|
||||
JS::Rooted<JSString*> displayId(aCx, JS_GetFunctionDisplayId(rootedFunction));
|
||||
if (displayId) {
|
||||
functionName.initTwoByte(aCx, displayId);
|
||||
if (!functionName.initTwoByte(aCx, displayId)) {
|
||||
JS_ClearPendingException(aCx);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1327,10 +1327,10 @@ class MOZ_STACK_CLASS AutoStableStringChars
|
||||
{}
|
||||
~AutoStableStringChars();
|
||||
|
||||
bool init(JSContext* cx, JSString* s);
|
||||
bool init(JSContext* cx, JSString* s) MOZ_WARN_UNUSED_RESULT;
|
||||
|
||||
/* Like init(), but Latin1 chars are inflated to TwoByte. */
|
||||
bool initTwoByte(JSContext* cx, JSString* s);
|
||||
bool initTwoByte(JSContext* cx, JSString* s) MOZ_WARN_UNUSED_RESULT;
|
||||
|
||||
bool isLatin1() const { return state_ == Latin1; }
|
||||
bool isTwoByte() const { return state_ == TwoByte; }
|
||||
|
Loading…
Reference in New Issue
Block a user