commit | 5d1e049b9a7065aa20f0f027145b62f52933bb69 | [log] [tgz] |
---|---|---|
author | Oliver Newman <olivernewman@google.com> | Tue Nov 03 16:02:28 2020 +0000 |
committer | CQ Bot <commit-bot@chromium.org> | Tue Nov 03 16:02:28 2020 +0000 |
tree | 09a45ac86ebddac433df695472a9d4d2514414de | |
parent | fcaa7b443fd49fb829c12ee8d993e8fc4f4c28c1 [diff] |
[debugsyms] Fix hang fxrev.dev/446355 introduced a hang in the queue() function because we allocate a channel of size N and then attempt to synchronously send 2*N jobs on the channel, so we block when trying to send job N+1. To fix this (and hopefully make the code more future-proof), append all the jobs to a non-preallocated slice, and only allocate a channel afterward using the length of the slice as the channel size. I also added a test for the queue() function and ran debugsyms locally to ensure this fixes the hangs. Bug: 61846 Change-Id: Idaf18d9c4454d6f76063f3516dfa0a754d28d360 Reviewed-on: https://fuchsia-review.googlesource.com/c/tools/+/446440 Reviewed-by: Anthony Fandrianto <atyfto@google.com> Commit-Queue: Oliver Newman <olivernewman@google.com>
All tools have been moved to fuchsia.git at https://fuchsia.googlesource.com/fuchsia/+/refs/heads/master/tools.