diff options
author | Sverker Eriksson <[email protected]> | 2019-04-09 16:29:21 +0200 |
---|---|---|
committer | Sverker Eriksson <[email protected]> | 2019-04-09 16:29:21 +0200 |
commit | 440ef99ddcd3cddb5f8f7bd23ec282c8efe32bd3 (patch) | |
tree | d2c47759da39a646907c67e4758907fd29a7eaad /lib/jinterface/java_src/com/ericsson/otp/erlang/OtpErlangRef.java | |
parent | f824686c3c519ab00582bb1f854fdfda5e4b1240 (diff) | |
download | otp-440ef99ddcd3cddb5f8f7bd23ec282c8efe32bd3.tar.gz otp-440ef99ddcd3cddb5f8f7bd23ec282c8efe32bd3.tar.bz2 otp-440ef99ddcd3cddb5f8f7bd23ec282c8efe32bd3.zip |
Revert "jinterface: Remove old encoding of pid,port,refs"
This reverts commit 3c7a387c21d7b0d054c22509828142a80e509317.
Diffstat (limited to 'lib/jinterface/java_src/com/ericsson/otp/erlang/OtpErlangRef.java')
-rw-r--r-- | lib/jinterface/java_src/com/ericsson/otp/erlang/OtpErlangRef.java | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/jinterface/java_src/com/ericsson/otp/erlang/OtpErlangRef.java b/lib/jinterface/java_src/com/ericsson/otp/erlang/OtpErlangRef.java index 2bf8d9a56b..2165397013 100644 --- a/lib/jinterface/java_src/com/ericsson/otp/erlang/OtpErlangRef.java +++ b/lib/jinterface/java_src/com/ericsson/otp/erlang/OtpErlangRef.java @@ -28,6 +28,7 @@ public class OtpErlangRef extends OtpErlangObject { // don't change this! private static final long serialVersionUID = -7022666480768586521L; + private final int tag; private final String node; private final int creation; @@ -48,6 +49,7 @@ public class OtpErlangRef extends OtpErlangObject { public OtpErlangRef(final OtpLocalNode self) { final OtpErlangRef r = self.createRef(); + tag = r.tag; ids = r.ids; creation = r.creation; node = r.node; @@ -68,6 +70,7 @@ public class OtpErlangRef extends OtpErlangObject { throws OtpErlangDecodeException { final OtpErlangRef r = buf.read_ref(); + tag = r.tag; node = r.node(); creation = r.creation(); @@ -87,6 +90,7 @@ public class OtpErlangRef extends OtpErlangObject { * another arbitrary number. */ public OtpErlangRef(final String node, final int id, final int creation) { + this.tag = OtpExternal.newRefTag; this.node = node; ids = new int[1]; ids[0] = id & 0x3ffff; // 18 bits @@ -134,6 +138,7 @@ public class OtpErlangRef extends OtpErlangObject { */ public OtpErlangRef(final int tag, final String node, final int[] ids, final int creation) { + this.tag = tag; this.node = node; // use at most 3 words @@ -157,7 +162,7 @@ public class OtpErlangRef extends OtpErlangObject { } protected int tag() { - return OtpExternal.newerRefTag; + return tag; } /** |