gora-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lewi...@apache.org
Subject [2/3] gora git commit: Non-final public static fields can be changed by external classes (by a malicious code or accidentally).
Date Fri, 04 Sep 2015 14:46:42 GMT
Non-final public static fields can be changed by external classes (by a malicious code or accidentally).


Project: http://git-wip-us.apache.org/repos/asf/gora/repo
Commit: http://git-wip-us.apache.org/repos/asf/gora/commit/4086ece8
Tree: http://git-wip-us.apache.org/repos/asf/gora/tree/4086ece8
Diff: http://git-wip-us.apache.org/repos/asf/gora/diff/4086ece8

Branch: refs/heads/master
Commit: 4086ece8cd2f9cd7a29bf46a1d290313c4e44d14
Parents: c8550d3
Author: Furkan KAMACI <furkankamaci@gmail.com>
Authored: Thu Sep 3 22:51:57 2015 +0300
Committer: Furkan KAMACI <furkankamaci@gmail.com>
Committed: Thu Sep 3 22:51:57 2015 +0300

----------------------------------------------------------------------
 .../java/org/apache/gora/cassandra/store/CassandraStore.java     | 4 ++--
 .../src/main/java/org/apache/gora/compiler/GoraCompiler.java     | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/gora/blob/4086ece8/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraStore.java
----------------------------------------------------------------------
diff --git a/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraStore.java
b/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraStore.java
index dc4cf06..0c98162 100644
--- a/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraStore.java
+++ b/gora-cassandra/src/main/java/org/apache/gora/cassandra/store/CassandraStore.java
@@ -96,12 +96,12 @@ public class CassandraStore<K, T extends PersistentBase> extends
DataStoreBase<K
    * Fixed string with value "UnionIndex" used to generate an extra column based on 
    * the original field's name
    */
-  public static String UNION_COL_SUFIX = "_UnionIndex";
+  public static final String UNION_COL_SUFIX = "_UnionIndex";
 
   /**
    * Default schema index with value "0" used when AVRO Union data types are stored
    */
-  public static int DEFAULT_UNION_SCHEMA = 0;
+  public static final int DEFAULT_UNION_SCHEMA = 0;
 
   /**
    * The values are Avro fields pending to be stored.

http://git-wip-us.apache.org/repos/asf/gora/blob/4086ece8/gora-compiler/src/main/java/org/apache/gora/compiler/GoraCompiler.java
----------------------------------------------------------------------
diff --git a/gora-compiler/src/main/java/org/apache/gora/compiler/GoraCompiler.java b/gora-compiler/src/main/java/org/apache/gora/compiler/GoraCompiler.java
index f0a04f4..3b9846f 100644
--- a/gora-compiler/src/main/java/org/apache/gora/compiler/GoraCompiler.java
+++ b/gora-compiler/src/main/java/org/apache/gora/compiler/GoraCompiler.java
@@ -36,7 +36,7 @@ import org.codehaus.jackson.node.JsonNodeFactory;
 
 public class GoraCompiler extends SpecificCompiler {
 
-  public static String DIRTY_BYTES_FIELD_NAME = "__g__dirty";
+  public static final String DIRTY_BYTES_FIELD_NAME = "__g__dirty";
   public static final int FIRST_UNMANAGED_FIELD_INDEX = 1;
 
   private static final Set<String> GORA_RESERVED_NAMES = new HashSet<String>();


Mime
View raw message