wok-next annotate js185/stuff/patches/fix-811665.patch @ rev 21087
Updates...
Revert names: libsdl -> sdl, libsmpeg -> smpeg, libtdb -> tdb
Revert names: libsdl -> sdl, libsmpeg -> smpeg, libtdb -> tdb
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Fri Dec 28 05:11:49 2018 +0200 (2018-12-28) |
parents | |
children |
rev | line source |
---|---|
al@20443 | 1 Description: Fix FTBFS with gcc6 |
al@20443 | 2 Most fixes are returning NULL instead of false and a narrowing issues. |
al@20443 | 3 Author: Tobias Frost <tobi@debian.org> |
al@20443 | 4 Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=811665 |
al@20443 | 5 Last-Update: 2016-09-25 |
al@20443 | 6 --- |
al@20443 | 7 This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ |
al@20443 | 8 --- a/js/src/ctypes/CTypes.cpp |
al@20443 | 9 +++ b/js/src/ctypes/CTypes.cpp |
al@20443 | 10 @@ -4753,7 +4753,7 @@ NewFunctionInfo(JSContext* cx, |
al@20443 | 11 for (JSUint32 i = 0; i < argLength; ++i) { |
al@20443 | 12 bool isEllipsis; |
al@20443 | 13 if (!IsEllipsis(cx, argTypes[i], &isEllipsis)) |
al@20443 | 14 - return false; |
al@20443 | 15 + return NULL; |
al@20443 | 16 if (isEllipsis) { |
al@20443 | 17 fninfo->mIsVariadic = true; |
al@20443 | 18 if (i < 1) { |
al@20443 | 19 --- a/js/src/jsapi.cpp |
al@20443 | 20 +++ b/js/src/jsapi.cpp |
al@20443 | 21 @@ -3985,7 +3985,7 @@ JS_Enumerate(JSContext *cx, JSObject *ob |
al@20443 | 22 AutoIdVector props(cx); |
al@20443 | 23 JSIdArray *ida; |
al@20443 | 24 if (!GetPropertyNames(cx, obj, JSITER_OWNONLY, &props) || !VectorToIdArray(cx, props, &ida)) |
al@20443 | 25 - return false; |
al@20443 | 26 + return NULL; |
al@20443 | 27 for (size_t n = 0; n < size_t(ida->length); ++n) |
al@20443 | 28 JS_ASSERT(js_CheckForStringIndex(ida->vector[n]) == ida->vector[n]); |
al@20443 | 29 return ida; |
al@20443 | 30 --- a/js/src/jsfun.cpp |
al@20443 | 31 +++ b/js/src/jsfun.cpp |
al@20443 | 32 @@ -2051,7 +2051,7 @@ fun_toStringHelper(JSContext *cx, JSObje |
al@20443 | 33 |
al@20443 | 34 JSString *str = JS_DecompileFunction(cx, fun, indent); |
al@20443 | 35 if (!str) |
al@20443 | 36 - return false; |
al@20443 | 37 + return NULL; |
al@20443 | 38 |
al@20443 | 39 if (!indent) |
al@20443 | 40 cx->compartment->toSourceCache.put(fun, str); |
al@20443 | 41 @@ -2657,7 +2657,7 @@ LookupInterpretedFunctionPrototype(JSCon |
al@20443 | 42 const Shape *shape = funobj->nativeLookup(id); |
al@20443 | 43 if (!shape) { |
al@20443 | 44 if (!ResolveInterpretedFunctionPrototype(cx, funobj)) |
al@20443 | 45 - return false; |
al@20443 | 46 + return NULL; |
al@20443 | 47 shape = funobj->nativeLookup(id); |
al@20443 | 48 } |
al@20443 | 49 JS_ASSERT(!shape->configurable()); |
al@20443 | 50 --- a/js/src/jsiter.cpp |
al@20443 | 51 +++ b/js/src/jsiter.cpp |
al@20443 | 52 @@ -425,7 +425,7 @@ NewIteratorObject(JSContext *cx, uintN f |
al@20443 | 53 */ |
al@20443 | 54 JSObject *obj = js_NewGCObject(cx, FINALIZE_OBJECT0); |
al@20443 | 55 if (!obj) |
al@20443 | 56 - return false; |
al@20443 | 57 + return NULL; |
al@20443 | 58 obj->init(cx, &js_IteratorClass, NULL, NULL, NULL, false); |
al@20443 | 59 obj->setMap(cx->compartment->emptyEnumeratorShape); |
al@20443 | 60 return obj; |
al@20443 | 61 --- a/js/src/jsparse.cpp |
al@20443 | 62 +++ b/js/src/jsparse.cpp |
al@20443 | 63 @@ -3352,7 +3352,7 @@ Parser::functionDef(JSAtom *funAtom, Fun |
al@20443 | 64 if (!outertc->inFunction() && bodyLevel && funAtom && !lambda && outertc->compiling()) { |
al@20443 | 65 JS_ASSERT(pn->pn_cookie.isFree()); |
al@20443 | 66 if (!DefineGlobal(pn, outertc->asCodeGenerator(), funAtom)) |
al@20443 | 67 - return false; |
al@20443 | 68 + return NULL; |
al@20443 | 69 } |
al@20443 | 70 |
al@20443 | 71 pn->pn_blockid = outertc->blockid(); |
al@20443 | 72 --- a/js/src/jsstr.cpp |
al@20443 | 73 +++ b/js/src/jsstr.cpp |
al@20443 | 74 @@ -1734,7 +1734,7 @@ class RegExpGuard |
al@20443 | 75 if (flat) { |
al@20443 | 76 patstr = flattenPattern(cx, fm.patstr); |
al@20443 | 77 if (!patstr) |
al@20443 | 78 - return false; |
al@20443 | 79 + return NULL; |
al@20443 | 80 } else { |
al@20443 | 81 patstr = fm.patstr; |
al@20443 | 82 } |
al@20443 | 83 @@ -3408,7 +3408,7 @@ js_InitStringClass(JSContext *cx, JSObje |
al@20443 | 84 UndefinedValue(), NULL, NULL, |
al@20443 | 85 JSPROP_READONLY | JSPROP_PERMANENT | JSPROP_SHARED, 0, 0, |
al@20443 | 86 NULL)) { |
al@20443 | 87 - return JS_FALSE; |
al@20443 | 88 + return NULL; |
al@20443 | 89 } |
al@20443 | 90 |
al@20443 | 91 return proto; |
al@20443 | 92 --- a/js/src/jstypedarray.cpp |
al@20443 | 93 +++ b/js/src/jstypedarray.cpp |
al@20443 | 94 @@ -1334,7 +1334,7 @@ class TypedArrayTemplate |
al@20443 | 95 if (size != 0 && count >= INT32_MAX / size) { |
al@20443 | 96 JS_ReportErrorNumber(cx, js_GetErrorMessage, NULL, |
al@20443 | 97 JSMSG_NEED_DIET, "size and count"); |
al@20443 | 98 - return false; |
al@20443 | 99 + return NULL; |
al@20443 | 100 } |
al@20443 | 101 |
al@20443 | 102 int32 bytelen = size * count; |
al@20443 | 103 @@ -1668,7 +1668,7 @@ TypedArrayConstruct(JSContext *cx, jsint |
al@20443 | 104 |
al@20443 | 105 default: |
al@20443 | 106 JS_NOT_REACHED("shouldn't have gotten here"); |
al@20443 | 107 - return false; |
al@20443 | 108 + return NULL; |
al@20443 | 109 } |
al@20443 | 110 } |
al@20443 | 111 |
al@20443 | 112 --- a/js/src/jsxml.cpp |
al@20443 | 113 +++ b/js/src/jsxml.cpp |
al@20443 | 114 @@ -282,7 +282,7 @@ NewXMLNamespace(JSContext *cx, JSLinearS |
al@20443 | 115 |
al@20443 | 116 obj = NewBuiltinClassInstanceXML(cx, &js_NamespaceClass); |
al@20443 | 117 if (!obj) |
al@20443 | 118 - return JS_FALSE; |
al@20443 | 119 + return NULL; |
al@20443 | 120 JS_ASSERT(JSVAL_IS_VOID(obj->getNamePrefixVal())); |
al@20443 | 121 JS_ASSERT(JSVAL_IS_VOID(obj->getNameURIVal())); |
al@20443 | 122 JS_ASSERT(JSVAL_IS_VOID(obj->getNamespaceDeclared())); |
al@20443 | 123 @@ -431,7 +431,7 @@ ConvertQNameToString(JSContext *cx, JSOb |
al@20443 | 124 size_t length = str->length(); |
al@20443 | 125 jschar *chars = (jschar *) cx->malloc((length + 2) * sizeof(jschar)); |
al@20443 | 126 if (!chars) |
al@20443 | 127 - return JS_FALSE; |
al@20443 | 128 + return NULL; |
al@20443 | 129 *chars = '@'; |
al@20443 | 130 const jschar *strChars = str->getChars(cx); |
al@20443 | 131 if (!strChars) { |
al@20443 | 132 --- a/js/src/methodjit/InvokeHelpers.cpp |
al@20443 | 133 +++ b/js/src/methodjit/InvokeHelpers.cpp |
al@20443 | 134 @@ -728,7 +728,7 @@ AtSafePoint(JSContext *cx) |
al@20443 | 135 { |
al@20443 | 136 JSStackFrame *fp = cx->fp(); |
al@20443 | 137 if (fp->hasImacropc()) |
al@20443 | 138 - return false; |
al@20443 | 139 + return NULL; |
al@20443 | 140 |
al@20443 | 141 JSScript *script = fp->script(); |
al@20443 | 142 return script->maybeNativeCodeForPC(fp->isConstructing(), cx->regs->pc); |
al@20443 | 143 --- a/js/src/nanojit/NativeX64.cpp |
al@20443 | 144 +++ b/js/src/nanojit/NativeX64.cpp |
al@20443 | 145 @@ -1899,7 +1899,7 @@ namespace nanojit |
al@20443 | 146 } |
al@20443 | 147 } |
al@20443 | 148 |
al@20443 | 149 - static const AVMPLUS_ALIGN16(int64_t) negateMask[] = {0x8000000000000000LL,0}; |
al@20443 | 150 + static const AVMPLUS_ALIGN16(int64_t) negateMask[] = {(int64_t) 0x8000000000000000ULL,0}; |
al@20443 | 151 |
al@20443 | 152 void Assembler::asm_fneg(LIns *ins) { |
al@20443 | 153 Register rr, ra; |