commit | 4c0c9c90e1ae4fb8ef7312833a825bc3c3bee62b | [log] [tgz] |
---|---|---|
author | Josh Gao <jmgao@google.com> | Thu Apr 18 16:46:42 2019 -0700 |
committer | Josh Gao <jmgao@google.com> | Thu Apr 18 16:58:30 2019 -0700 |
tree | 8e02ad6551dcc3593b5105963c1d1d5a72fceefc | |
parent | f868dac363535c7f1c49fac4beb1d1fe4c7a9b97 [diff] |
adb: fix double close in wait-for-*. unique_fd's implicit conversion to int allows the following code to compile without error, leading to a double close: std::function<void(unique_fd)> func = [](int x) { close(x); }; func(unique_fd(42)); Test: treehugger Change-Id: I948ecda3a12738b3af6444fe2902d2f7b80e1b4c