Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(223)

Issue 1308813008: Fix crash when accessing automation node from stale AX tree (Closed)

Created:
5 years, 3 months ago by dmazzoni
Modified:
5 years, 3 months ago
Reviewers:
David Tseng
CC:
chromium-reviews, chromium-apps-reviews_chromium.org, extensions-reviews_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Fix crash when accessing automation node from stale AX tree The problem is that the root node of a stale AX tree computes its id dynamically, but if that AX tree doesn't exist anymore it was returning undefined, and then passing undefined to any of the native bindinds was a fatal error. The solution is just to return -1 instead of undefined as the id. BUG=526255 Committed: https://crrev.com/ace50646dcd95261ef8e6aca2096458828532fbc Cr-Commit-Position: refs/heads/master@{#346394}

Patch Set 1 #

Patch Set 2 : Add test #

Patch Set 3 : Put setTimeout in else to be more clear #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+17 lines, -5 lines) Patch
M chrome/renderer/resources/extensions/automation/automation_node.js View 1 chunk +8 lines, -1 line 0 comments Download
M chrome/test/data/extensions/api_test/automation/tests/tabs/close_tab.js View 1 2 1 chunk +9 lines, -4 lines 2 comments Download

Depends on Patchset:

Messages

Total messages: 14 (4 generated)
dmazzoni
5 years, 3 months ago (2015-08-28 20:14:59 UTC) #2
David Tseng
Thanks for the fix. Could we get a test for this?
5 years, 3 months ago (2015-08-28 21:57:28 UTC) #3
dmazzoni
Done - modified an existing test so that it triggers the crash without this patch.
5 years, 3 months ago (2015-08-28 22:38:32 UTC) #4
David Tseng
lgtm https://codereview.chromium.org/1308813008/diff/40001/chrome/test/data/extensions/api_test/automation/tests/tabs/close_tab.js File chrome/test/data/extensions/api_test/automation/tests/tabs/close_tab.js (right): https://codereview.chromium.org/1308813008/diff/40001/chrome/test/data/extensions/api_test/automation/tests/tabs/close_tab.js#newcode11 chrome/test/data/extensions/api_test/automation/tests/tabs/close_tab.js:11: // Poll until the root node doesn't have ...
5 years, 3 months ago (2015-08-28 22:51:25 UTC) #5
dmazzoni
https://codereview.chromium.org/1308813008/diff/40001/chrome/test/data/extensions/api_test/automation/tests/tabs/close_tab.js File chrome/test/data/extensions/api_test/automation/tests/tabs/close_tab.js (right): https://codereview.chromium.org/1308813008/diff/40001/chrome/test/data/extensions/api_test/automation/tests/tabs/close_tab.js#newcode11 chrome/test/data/extensions/api_test/automation/tests/tabs/close_tab.js:11: // Poll until the root node doesn't have a ...
5 years, 3 months ago (2015-08-28 23:02:36 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1308813008/40001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1308813008/40001
5 years, 3 months ago (2015-08-28 23:05:05 UTC) #8
commit-bot: I haz the power
Try jobs failed on following builders: win_chromium_x64_rel_ng on tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_x64_rel_ng/builds/97526)
5 years, 3 months ago (2015-08-29 00:24:52 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1308813008/40001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1308813008/40001
5 years, 3 months ago (2015-08-31 14:59:24 UTC) #12
commit-bot: I haz the power
Committed patchset #3 (id:40001)
5 years, 3 months ago (2015-08-31 16:15:36 UTC) #13
commit-bot: I haz the power
5 years, 3 months ago (2015-08-31 16:16:11 UTC) #14
Message was sent while issue was closed.
Patchset 3 (id:??) landed as
https://crrev.com/ace50646dcd95261ef8e6aca2096458828532fbc
Cr-Commit-Position: refs/heads/master@{#346394}

Powered by Google App Engine
This is Rietveld 408576698