Changeset 164008 in webkit
- Timestamp:
- Feb 12, 2014, 8:05:10 PM (11 years ago)
- Location:
- trunk
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r164000 r164008 1 2014-02-12 Alexey Proskuryakov <ap@apple.com> 2 3 Don't crash when SerializedScriptValue deserialization fails 4 https://bugs.webkit.org/show_bug.cgi?id=128657 5 6 Reviewed by Oliver Hunt. 7 8 * crypto/subtle/postMessage-worker-expected.txt: 9 * crypto/subtle/resources/postMessage-worker.js: 10 * platform/mac/TestExpectations: 11 Unskip the test, and land (unimportant) failure results. 12 1 13 2014-02-12 Brady Eidson <beidson@apple.com> 2 14 -
trunk/LayoutTests/crypto/subtle/postMessage-worker-expected.txt
r160547 r164008 4 4 5 5 6 PASS All checks passed in worker 7 PASS key.type is 'secret' 8 PASS key.extractable is true 9 PASS key.algorithm.name is 'HMAC' 10 PASS key.algorithm.length is 16 11 PASS key.usages is ["decrypt", "encrypt", "sign", "verify"] 6 FAIL Check failed in worker: key is null 12 7 PASS successfullyParsed is true 13 8 -
trunk/LayoutTests/crypto/subtle/resources/postMessage-worker.js
r160547 r164008 2 2 { 3 3 var key = evt.data; 4 if (!key) 5 postMessage({ result:false, message:'key is ' + key }); 4 6 if (key.type != 'secret') 5 7 postMessage({ result:false, message:'key.type should be "secret"' }); -
trunk/LayoutTests/platform/mac/TestExpectations
r163981 r164008 1246 1246 webkit.org/b/124261 [ MountainLion ] crypto/subtle [ Skip ] 1247 1247 1248 # Deserialization of a CryptoKey in a worker fails with a crash.1249 crypto/subtle/postMessage-worker.html [ Skip ]1250 1251 1248 webkit.org/b/124311 compositing/regions/transform-transparent-positioned-video-inside-region.html [ Pass ImageOnlyFailure ] 1252 1249 -
trunk/Source/WebCore/ChangeLog
r164006 r164008 1 2014-02-11 Alexey Proskuryakov <ap@apple.com> 2 3 Don't crash when SerializedScriptValue deserialization fails 4 https://bugs.webkit.org/show_bug.cgi?id=128657 5 6 Reviewed by Oliver Hunt. 7 8 Test: crypto/subtle/postMessage-worker.html 9 10 * bindings/js/JSMessageEventCustom.cpp: (WebCore::JSMessageEvent::data): Added a FIXME. 11 12 * bindings/js/SerializedScriptValue.cpp: 13 (WebCore::CloneBase::fail): Don't assert on failure. 14 (WebCore::SerializedScriptValue::deserialize): Never return a null JSValue, these 15 are not allowed. 16 1 17 2014-02-12 Bem Jones-Bey <bjonesbe@adobe.com> 2 18 -
trunk/Source/WebCore/bindings/js/JSMessageEventCustom.cpp
r163744 r164008 65 65 if (RefPtr<SerializedScriptValue> serializedValue = event.dataAsSerializedScriptValue()) { 66 66 MessagePortArray ports = impl().ports(); 67 // FIXME: Why does this suppress exceptions? 67 68 result = serializedValue->deserialize(exec, globalObject(), &ports, NonThrowing); 68 } 69 else 69 } else 70 70 result = jsNull(); 71 71 break; -
trunk/Source/WebCore/bindings/js/SerializedScriptValue.cpp
r163863 r164008 382 382 } 383 383 384 NO_RETURN_DUE_TO_ASSERT385 384 void fail() 386 385 { 387 ASSERT_NOT_REACHED();388 386 m_failed = true; 389 387 } … … 2642 2640 if (throwExceptions == Throwing) 2643 2641 maybeThrowExceptionIfSerializationFailed(exec, result.second); 2644 return result.first ;2642 return result.first ? result.first : jsNull(); 2645 2643 } 2646 2644 … … 2654 2652 *exception = toRef(exec, exec->exception()); 2655 2653 exec->clearException(); 2656 return 0;2654 return nullptr; 2657 2655 } 2658 2656 ASSERT(value);
Note:
See TracChangeset
for help on using the changeset viewer.