RESOLVED FIXED84982
[BlackBerry] run-time websocket availability check was lost
https://bugs.webkit.org/show_bug.cgi?id=84982
Summary [BlackBerry] run-time websocket availability check was lost
Joe Mason
Reported 2012-04-26 11:54:40 PDT
The patch to check if websocket is available at runtime was lost when JSDOMWindow::webSocket moved to JSDOMWindowWebSocketCustom.cpp.
Attachments
patch (7.32 KB, patch)
2012-04-27 09:08 PDT, Joe Mason
no flags
Archive of layout-test-results from ec2-cq-02 (6.00 MB, application/zip)
2012-04-27 13:43 PDT, WebKit Review Bot
no flags
Archive of layout-test-results from ec2-cq-01 (5.98 MB, application/zip)
2012-04-27 16:04 PDT, WebKit Review Bot
no flags
Archive of layout-test-results from ec2-cr-linux-03 (5.68 MB, application/zip)
2012-04-27 20:49 PDT, WebKit Review Bot
no flags
Patch (6.67 KB, patch)
2012-10-12 08:30 PDT, Rob Buis
no flags
Patch (6.50 KB, patch)
2012-10-12 08:48 PDT, Rob Buis
no flags
Patch (4.46 KB, patch)
2012-10-12 11:05 PDT, Rob Buis
no flags
Patch (4.48 KB, patch)
2012-10-12 11:07 PDT, Rob Buis
yong.li.webkit: review+
Joe Mason
Comment 1 2012-04-27 09:08:23 PDT
WebKit Review Bot
Comment 2 2012-04-27 09:11:54 PDT
Attachment 139213 [details] did not pass style-queue: Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'LayoutTests/platform/blackberry/http/tests..." exit_code: 1 Source/WebCore/bindings/js/JSDOMWindowWebSocketCustom.cpp:32: Found header this file implements after other header. Should be: config.h, primary header, blank line, and then alphabetically sorted. [build/include_order] [4] Total errors found: 1 in 6 files If any of these errors are false positives, please file a bug against check-webkit-style.
Joe Mason
Comment 3 2012-04-27 10:02:58 PDT
Comment on attachment 139213 [details] patch View in context: https://bugs.webkit.org/attachment.cgi?id=139213&action=review >> Source/WebCore/bindings/js/JSDOMWindowWebSocketCustom.cpp:32 >> +#include "WebSocket.h" > > Found header this file implements after other header. Should be: config.h, primary header, blank line, and then alphabetically sorted. [build/include_order] [4] This is a false positive. Filed bug 85075. For now this will have to be committed by hand.
WebKit Review Bot
Comment 4 2012-04-27 13:43:05 PDT
Comment on attachment 139213 [details] patch Rejecting attachment 139213 [details] from commit-queue. New failing tests: platform/blackberry/http/tests/websocket/tests/enable-disable-setting.html Full output: http://queues.webkit.org/results/12549321
WebKit Review Bot
Comment 5 2012-04-27 13:43:11 PDT
Created attachment 139263 [details] Archive of layout-test-results from ec2-cq-02 The attached test failures were seen while running run-webkit-tests on the commit-queue. Bot: ec2-cq-02 Port: <class 'webkitpy.common.config.ports.ChromiumXVFBPort'> Platform: Linux-2.6.35-28-virtual-x86_64-with-Ubuntu-10.10-maverick
WebKit Review Bot
Comment 6 2012-04-27 16:04:41 PDT
Comment on attachment 139213 [details] patch Rejecting attachment 139213 [details] from commit-queue. New failing tests: platform/blackberry/http/tests/websocket/tests/enable-disable-setting.html Full output: http://queues.webkit.org/results/12555379
WebKit Review Bot
Comment 7 2012-04-27 16:04:46 PDT
Created attachment 139298 [details] Archive of layout-test-results from ec2-cq-01 The attached test failures were seen while running run-webkit-tests on the commit-queue. Bot: ec2-cq-01 Port: <class 'webkitpy.common.config.ports.ChromiumXVFBPort'> Platform: Linux-2.6.35-28-virtual-x86_64-with-Ubuntu-10.10-maverick
Antonio Gomes
Comment 8 2012-04-27 20:45:37 PDT
Is chromium trying to run a layout test added to layouttests/platform/blackberry?
WebKit Review Bot
Comment 9 2012-04-27 20:49:10 PDT
Comment on attachment 139213 [details] patch Attachment 139213 [details] did not pass chromium-ews (chromium-xvfb): Output: http://queues.webkit.org/results/12552470 New failing tests: platform/blackberry/http/tests/websocket/tests/enable-disable-setting.html
WebKit Review Bot
Comment 10 2012-04-27 20:49:16 PDT
Created attachment 139331 [details] Archive of layout-test-results from ec2-cr-linux-03 The attached test failures were seen while running run-webkit-tests on the chromium-ews. Bot: ec2-cr-linux-03 Port: <class 'webkitpy.common.config.ports.ChromiumXVFBPort'> Platform: Linux-2.6.35-28-virtual-x86_64-with-Ubuntu-10.10-maverick
Rob Buis
Comment 11 2012-10-12 08:30:19 PDT
WebKit Review Bot
Comment 12 2012-10-12 08:32:17 PDT
Attachment 168422 [details] did not pass style-queue: Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'LayoutTests/ChangeLog', u'LayoutTests/plat..." exit_code: 1 Source/WebCore/bindings/js/JSDOMWindowWebSocketCustom.cpp:31: Found header this file implements after other header. Should be: config.h, primary header, blank line, and then alphabetically sorted. [build/include_order] [4] Total errors found: 1 in 7 files If any of these errors are false positives, please file a bug against check-webkit-style.
Rob Buis
Comment 13 2012-10-12 08:48:59 PDT
Yong Li
Comment 14 2012-10-12 10:09:27 PDT
Comment on attachment 168427 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=168427&action=review > Source/WebCore/bindings/js/JSDOMWindowWebSocketCustom.cpp:57 > JSValue JSDOMWindow::webSocket(ExecState* exec) const > { > if (!settingsForWindowWebSocket(this)) > return jsUndefined(); > +#if PLATFORM(BLACKBERRY) > + // FIXME: returning undefined is not the same things as disabling the > + // WebSocket object completely. But, this is the best we can do without > + // changing the code generation to check RuntimeEnabledFeatures, like V8 > + // does, which is too big a job at the moment. Remove this check when > + // https://bugs.webkit.org/show_bug.cgi?id=52011 is fixed. > + if (!WebSocket::isAvailable()) > + return jsUndefined(); > +#endif > return getDOMConstructor<JSWebSocketConstructor>(exec, this); > } I don't like this #if PLATFORM(). Does returning jsUndefined when !WebSocket::isAvailable() also make sense to other ports?
Rob Buis
Comment 15 2012-10-12 11:05:10 PDT
Rob Buis
Comment 16 2012-10-12 11:07:03 PDT
Joe Mason
Comment 17 2012-10-12 12:59:36 PDT
(In reply to comment #14) > I don't like this #if PLATFORM(). Does returning jsUndefined when !WebSocket::isAvailable() also make sense to other ports? Not really - it's kind of a hack. The correct thing to do is to drop "websocket" from the list of properties entirely, which only works under V8. (There's a bug open about that.) If other ports want to take advantage of this they can add themselves to the ifdef, but it would be rude to turn this behaviour on by default.
Rob Buis
Comment 18 2013-01-04 10:02:22 PST
This landed in r131204, closing.
Note You need to log in before you can comment on or make changes to this bug.