diff options
author | Wladimir J. van der Laan <laanwj@gmail.com> | 2018-08-25 17:57:05 +0200 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2018-08-25 18:18:15 +0200 |
commit | 021dce935af25adc17ae04a721d5f74a2ea1ca76 (patch) | |
tree | c52642548b715b67e9016fad05a0f62640c7f6e8 /src/streams.h | |
parent | 4cef8e05938e55d2d1bb3c36642aa294fb63b6e2 (diff) | |
parent | fa6c3dea420b6c50c164ccc34f4e9e8a7d9a8022 (diff) | |
download | bitcoin-021dce935af25adc17ae04a721d5f74a2ea1ca76.tar.xz |
Merge #13946: p2p: Clarify control flow in ProcessMessage
fa6c3dea420b6c50c164ccc34f4e9e8a7d9a8022 p2p: Clarify control flow in ProcessMessage() (MarcoFalke)
Pull request description:
`ProcessMessage` is effectively a massive switch case construct. In the past there were attempts to clarify the control flow in `ProcessMessage()` by moving each case into a separate static function (see #9608). It was closed because it wasn't clear if moving each case into a function was the right approach.
Though, we can quasi treat each case as a function by adding a return statement to each case. (Can be seen as a continuation of bugfix #13162)
This patch does exactly that.
Also note that this patch is a subset of previous approaches such as #9608 and #10145.
Review suggestion: `git diff HEAD~ --function-context`
Tree-SHA512: 91f6106840de2f29bb4f10d27bae0616b03a91126e6c6013479e1dd79bee53f22a78902b631fe85517dd5dc0fa7239939b4fefc231851a13c819458559f6c201
Diffstat (limited to 'src/streams.h')
0 files changed, 0 insertions, 0 deletions