|
|
Chromium Code Reviews|
Created:
4 years ago by Reilly Grant (use Gerrit) Modified:
4 years ago Reviewers:
juncai CC:
chromium-reviews Target Ref:
refs/pending/heads/master Project:
chromium Visibility:
Public. |
DescriptionPrevent timed-out USB transfers from being cancelled twice.
If a transfer times out then when the connection is closed the transfer
will be cancelled again. This violates the contract that transfer
callbacks should only be called once and can thus cause issues with
client code.
BUG=675012
Committed: https://crrev.com/64539fbea7bd7bbac3933e9413b9502e77633104
Cr-Commit-Position: refs/heads/master@{#439912}
Patch Set 1 #Patch Set 2 : Reset callbacks after they are run. #
Total comments: 2
Patch Set 3 : Move |urb| field back to the end of the Transfer struct. #Messages
Total messages: 23 (15 generated)
Description was changed from ========== Prevent timed-out USB transfers from being cancelled twice. If a transfer times out then when the connection is closed the transfer will be cancelled again. This violates the contract that transfer callbacks should only be called once (they will be changed to OnceCallbacks in a follow-up patch) and can thus cause issues with client code. BUG=675012 ========== to ========== Prevent timed-out USB transfers from being cancelled twice. If a transfer times out then when the connection is closed the transfer will be cancelled again. This violates the contract that transfer callbacks should only be called once and can thus cause issues with client code. BUG=675012 ==========
reillyg@chromium.org changed reviewers: + juncai@chromium.org
Reset callbacks after they are run.
The CQ bit was checked by reillyg@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
Description was changed from ========== Prevent timed-out USB transfers from being cancelled twice. If a transfer times out then when the connection is closed the transfer will be cancelled again. This violates the contract that transfer callbacks should only be called once (they will be changed to OnceCallbacks in a follow-up patch) and can thus cause issues with client code. BUG=675012 ========== to ========== Prevent timed-out USB transfers from being cancelled twice. If a transfer times out then when the connection is closed the transfer will be cancelled again. This violates the contract that transfer callbacks should only be called once and can thus cause issues with client code. BUG=675012 ==========
reillyg@chromium.org changed reviewers: + juncai@chromium.org
Please take a look.
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
https://codereview.chromium.org/2584093002/diff/20001/device/usb/usb_device_h... File device/usb/usb_device_handle_usbfs.cc (right): https://codereview.chromium.org/2584093002/diff/20001/device/usb/usb_device_h... device/usb/usb_device_handle_usbfs.cc:254: TransferCallback callback; The comment for the above |urb| variable says: "The |urb| field must be the last in the struct ...", so by moving these three variables after |urb|, it may affect the overridden new function?
The CQ bit was checked by reillyg@chromium.org to run a CQ dry run
https://codereview.chromium.org/2584093002/diff/20001/device/usb/usb_device_h... File device/usb/usb_device_handle_usbfs.cc (right): https://codereview.chromium.org/2584093002/diff/20001/device/usb/usb_device_h... device/usb/usb_device_handle_usbfs.cc:254: TransferCallback callback; On 2016/12/20 18:18:54, juncai wrote: > The comment for the above |urb| variable says: "The |urb| field must be the last > in the struct ...", so by moving these three variables after |urb|, it may > affect the overridden new function? Done, good catch.
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
LGTM.
The CQ bit was unchecked by reillyg@chromium.org
The CQ bit was checked by reillyg@chromium.org
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
CQ is committing da patch.
Bot data: {"patchset_id": 40001, "attempt_start_ts": 1482274080178230,
"parent_rev": "34bf74902c5f5e962e444c4aa5f5f421aa9d7bfa", "commit_rev":
"5f6c1d7425be7c0cd76a0e47ad83051d2914a2c7"}
Message was sent while issue was closed.
Description was changed from ========== Prevent timed-out USB transfers from being cancelled twice. If a transfer times out then when the connection is closed the transfer will be cancelled again. This violates the contract that transfer callbacks should only be called once and can thus cause issues with client code. BUG=675012 ========== to ========== Prevent timed-out USB transfers from being cancelled twice. If a transfer times out then when the connection is closed the transfer will be cancelled again. This violates the contract that transfer callbacks should only be called once and can thus cause issues with client code. BUG=675012 Review-Url: https://codereview.chromium.org/2584093002 ==========
Message was sent while issue was closed.
Committed patchset #3 (id:40001)
Message was sent while issue was closed.
Description was changed from ========== Prevent timed-out USB transfers from being cancelled twice. If a transfer times out then when the connection is closed the transfer will be cancelled again. This violates the contract that transfer callbacks should only be called once and can thus cause issues with client code. BUG=675012 Review-Url: https://codereview.chromium.org/2584093002 ========== to ========== Prevent timed-out USB transfers from being cancelled twice. If a transfer times out then when the connection is closed the transfer will be cancelled again. This violates the contract that transfer callbacks should only be called once and can thus cause issues with client code. BUG=675012 Committed: https://crrev.com/64539fbea7bd7bbac3933e9413b9502e77633104 Cr-Commit-Position: refs/heads/master@{#439912} ==========
Message was sent while issue was closed.
Patchset 3 (id:??) landed as https://crrev.com/64539fbea7bd7bbac3933e9413b9502e77633104 Cr-Commit-Position: refs/heads/master@{#439912} |
