diff options
author | Florian Mayer <fmayer@google.com> | 2022-02-24 15:08:51 -0800 |
---|---|---|
committer | Florian Mayer <fmayer@google.com> | 2022-02-24 15:12:33 -0800 |
commit | 634f84fed41f8c46b4014de9bd40a2ebdf485deb (patch) | |
tree | 919c89a6bb602a5477c45c09dbbaf45fefe065a6 | |
parent | 2fcf57e9fd260db88c8abfa014eab775b86db76b (diff) | |
download | libhwbinder-634f84fed41f8c46b4014de9bd40a2ebdf485deb.tar.gz |
Remove unnecessarily complicated code.
Change-Id: If2bd0b49cb8de28aa652f03e1fcd16efa9bf648e
-rw-r--r-- | Binder.cpp | 20 |
1 files changed, 6 insertions, 14 deletions
@@ -129,20 +129,12 @@ status_t BHwBinder::transact( } } - status_t err = NO_ERROR; - switch (code) { - default: - err = onTransact(code, data, reply, flags, - [&](auto &replyParcel) { - replyParcel.setDataPosition(0); - if (callback != nullptr) { - callback(replyParcel); - } - }); - break; - } - - return err; + return onTransact(code, data, reply, flags, [&](auto& replyParcel) { + replyParcel.setDataPosition(0); + if (callback != nullptr) { + callback(replyParcel); + } + }); } status_t BHwBinder::linkToDeath( |