aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/beam/register.c
diff options
context:
space:
mode:
authorRickard Green <[email protected]>2012-08-02 18:21:50 +0200
committerRickard Green <[email protected]>2012-12-03 21:18:04 +0100
commit6da93c20472f5d13b34a40ca53cba4fe6f352d24 (patch)
tree5b1aa9146d389eaed4960172466a09cd9a671dc1 /erts/emulator/beam/register.c
parentd827ac847517ed43339a6a86493c7c017be782a5 (diff)
downloadotp-6da93c20472f5d13b34a40ca53cba4fe6f352d24.tar.gz
otp-6da93c20472f5d13b34a40ca53cba4fe6f352d24.tar.bz2
otp-6da93c20472f5d13b34a40ca53cba4fe6f352d24.zip
Generalize process table implementation
Diffstat (limited to 'erts/emulator/beam/register.c')
-rw-r--r--erts/emulator/beam/register.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/erts/emulator/beam/register.c b/erts/emulator/beam/register.c
index c02872ef80..9011eb0c10 100644
--- a/erts/emulator/beam/register.c
+++ b/erts/emulator/beam/register.c
@@ -204,7 +204,7 @@ int erts_register_name(Process *c_p, Eterm name, Eterm id)
r.p = proc;
if (!proc)
goto done;
- if (proc->reg)
+ if (proc->common.u.alive.reg)
goto done;
r.pt = NULL;
}
@@ -224,7 +224,7 @@ int erts_register_name(Process *c_p, Eterm name, Eterm id)
if (IS_TRACED_FL(proc, F_TRACE_PROCS)) {
trace_proc(c_p, proc, am_register, name);
}
- proc->reg = rp;
+ proc->common.u.alive.reg = rp;
}
else if (port && rp->pt == port) {
if (IS_TRACED_FL(port, F_TRACE_PORTS)) {
@@ -493,8 +493,8 @@ int erts_unregister_name(Process *c_p,
current_c_p_locks = c_p_locks;
}
#endif
- if (c_p->reg) {
- r.name = c_p->reg->name;
+ if (c_p->common.u.alive.reg) {
+ r.name = c_p->common.u.alive.reg->name;
} else {
/* Name got unregistered while main lock was released */
res = 0;
@@ -549,7 +549,7 @@ int erts_unregister_name(Process *c_p,
ERTS_PROC_LOCK_MAIN);
current_c_p_locks = c_p_locks;
#endif
- rp->p->reg = NULL;
+ rp->p->common.u.alive.reg = NULL;
if (IS_TRACED_FL(rp->p, F_TRACE_PROCS)) {
trace_proc(c_p, rp->p, am_unregister, r.name);
}