ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From voze...@apache.org
Subject [07/10] ignite git commit: IGNITE-1770: Removed weird optimization preventing correct field metadata collection.
Date Mon, 26 Oct 2015 15:12:05 GMT
IGNITE-1770: Removed weird optimization preventing correct field metadata collection.


Project: http://git-wip-us.apache.org/repos/asf/ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/95203cd4
Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/95203cd4
Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/95203cd4

Branch: refs/heads/ignite-1770
Commit: 95203cd49fe81abe09c9c030092b3a6ee2ad082b
Parents: 85d4985
Author: vozerov-gridgain <vozerov@gridgain.com>
Authored: Mon Oct 26 17:43:02 2015 +0300
Committer: vozerov-gridgain <vozerov@gridgain.com>
Committed: Mon Oct 26 17:43:02 2015 +0300

----------------------------------------------------------------------
 .../internal/portable/builder/PortableBuilderImpl.java    | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/95203cd4/modules/core/src/main/java/org/apache/ignite/internal/portable/builder/PortableBuilderImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/portable/builder/PortableBuilderImpl.java
b/modules/core/src/main/java/org/apache/ignite/internal/portable/builder/PortableBuilderImpl.java
index 7dbfd49..e66b88d 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/portable/builder/PortableBuilderImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/portable/builder/PortableBuilderImpl.java
@@ -230,8 +230,8 @@ public class PortableBuilderImpl implements PortableBuilder {
                 int fieldId = reader.readInt();
                 int fieldLen = reader.readInt();
 
-                if (assignedFldsById.containsKey(fldId)) {
-                    Object assignedVal = assignedFldsById.remove(fldId);
+                if (assignedFldsById.containsKey(fieldId)) {
+                    Object assignedVal = assignedFldsById.remove(fieldId);
 
                     reader.skip(fieldLen);
 
@@ -248,15 +248,15 @@ public class PortableBuilderImpl implements PortableBuilder {
                 else {
                     int type = fieldLen != 0 ? reader.readByte(0) : 0;
 
-                    if (len != 0 && !PortableUtils.isPlainArrayType(type) &&
PortableUtils.isPlainType(type)) {
+                    if (fieldLen != 0 && !PortableUtils.isPlainArrayType(type) &&
PortableUtils.isPlainType(type)) {
                         writer.writeInt(fieldId);
                         writer.writeInt(fieldLen);
-                        writer.write(reader.array(), reader.position(), len);
+                        writer.write(reader.array(), reader.position(), fieldLen);
 
                         reader.skip(fieldLen);
                     }
                     else {
-                        writer.writeInt(fldId);
+                        writer.writeInt(fieldId);
 
                         Object val;
 


Mime
View raw message