diff options
author | Sverker Eriksson <[email protected]> | 2018-03-01 16:36:17 +0100 |
---|---|---|
committer | Sverker Eriksson <[email protected]> | 2018-03-02 19:16:48 +0100 |
commit | b31750711daa35011c62898d2eb424332e170bcc (patch) | |
tree | b1501632709de066436d93f63f8bffed915fd39e /erts/emulator/beam/external.c | |
parent | c10e3e1fc83cbccd1c8c3b377e2309ea8fa27572 (diff) | |
download | otp-b31750711daa35011c62898d2eb424332e170bcc.tar.gz otp-b31750711daa35011c62898d2eb424332e170bcc.tar.bz2 otp-b31750711daa35011c62898d2eb424332e170bcc.zip |
erts: Refactor DistEntry.status flags into a state
Just to simplify and get 4 distinctive states
IDLE, PENDING, CONNECTED and EXITING.
The old possible flag combos were:
0
PENDING
CONNECTED
CONNECTED|EXITING
EXITING
The two EXITING states did not serve any purpose
other then as a slight optimization in monitor_node(_,false,_)
to shortcut EXITING when there can be no monitors.
Diffstat (limited to 'erts/emulator/beam/external.c')
-rw-r--r-- | erts/emulator/beam/external.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/erts/emulator/beam/external.c b/erts/emulator/beam/external.c index b358685cc0..314005e18d 100644 --- a/erts/emulator/beam/external.c +++ b/erts/emulator/beam/external.c @@ -711,8 +711,8 @@ erts_prepare_dist_ext(ErtsDistExternal *edep, erts_de_rlock(dep); - if (dep->status != ERTS_DE_SFLG_CONNECTED && - dep->status != ERTS_DE_SFLG_PENDING) { + if (dep->state != ERTS_DE_STATE_CONNECTED && + dep->state != ERTS_DE_STATE_PENDING) { erts_de_runlock(dep); return ERTS_PREP_DIST_EXT_CLOSED; } |