From: Apple Date: Sat, 14 Feb 2015 10:38:57 +0000 (+0000) Subject: JavaScriptCore-1218.34.tar.gz X-Git-Tag: ios-711^0 X-Git-Url: https://git.saurik.com/apple/javascriptcore.git/commitdiff_plain/217a6308cd6a1dc049a0bb69263bd4c91f91c4d0 JavaScriptCore-1218.34.tar.gz --- diff --git a/runtime/JSStringJoiner.cpp b/runtime/JSStringJoiner.cpp index 7e20d21..b6461c7 100644 --- a/runtime/JSStringJoiner.cpp +++ b/runtime/JSStringJoiner.cpp @@ -102,13 +102,13 @@ JSValue JSStringJoiner::join(ExecState* exec) if (!m_strings.size()) return jsEmptyString(exec); - Checked separatorLength = m_separator.length(); + Checked separatorLength = m_separator.length(); // FIXME: add special cases of joinStrings() for (separatorLength == 0) and (separatorLength == 1). ASSERT(m_strings.size() > 0); - Checked totalSeparactorsLength = separatorLength * (m_strings.size() - 1); - Checked outputStringSize = totalSeparactorsLength + m_accumulatedStringsLength; + Checked totalSeparactorsLength = separatorLength * (m_strings.size() - 1); + Checked outputStringSize = totalSeparactorsLength + m_accumulatedStringsLength; - size_t finalSize; + unsigned finalSize; if (outputStringSize.safeGet(finalSize) == CheckedState::DidOverflow) return throwOutOfMemoryError(exec);