зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1442750 - Slience a few Clang-only warnings in SpiderMonkey. r=jorendorff
The changes in shell/js.cpp silence warnings about unreachable return statements. The constant being removed in testErrorInterceptor.cpp is unused. --HG-- extra : rebase_source : 8f57e671265a82a3baeb9d74cf38711383239a76
This commit is contained in:
Родитель
693efc04e8
Коммит
42e72ffaa9
|
@ -8,8 +8,6 @@
|
|||
|
||||
|
||||
namespace {
|
||||
const double EXN_VALUE = 3.14;
|
||||
|
||||
static JS::PersistentRootedString gLatestMessage;
|
||||
|
||||
// An interceptor that stores the error in `gLatestMessage`.
|
||||
|
|
|
@ -719,7 +719,7 @@ GetLine(FILE* file, const char * prompt)
|
|||
if (*t == '\n') {
|
||||
/* Line was read. We remove '\n' and exit. */
|
||||
*t = '\0';
|
||||
return buffer;
|
||||
break;
|
||||
}
|
||||
|
||||
if (len + 1 == size) {
|
||||
|
@ -733,7 +733,7 @@ GetLine(FILE* file, const char * prompt)
|
|||
}
|
||||
current = buffer + len;
|
||||
} while (true);
|
||||
return nullptr;
|
||||
return buffer;
|
||||
}
|
||||
|
||||
static bool
|
||||
|
@ -7222,7 +7222,9 @@ WasmLoop(JSContext* cx, unsigned argc, Value* vp)
|
|||
}
|
||||
}
|
||||
|
||||
#ifdef __AFL_HAVE_MANUAL_CONTROL // to silence unreachable code warning
|
||||
return true;
|
||||
#endif
|
||||
}
|
||||
|
||||
static const JSFunctionSpecWithHelp shell_functions[] = {
|
||||
|
|
Загрузка…
Ссылка в новой задаче