ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From voze...@apache.org
Subject [12/12] ignite git commit: Minors.
Date Tue, 23 Aug 2016 09:39:21 GMT
Minors.


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

Branch: refs/heads/ignite-3716-1
Commit: d087c782768abf52ab2f162568ed264dc5dea428
Parents: e48853d
Author: vozerov-gridgain <vozerov@gridgain.com>
Authored: Tue Aug 23 12:38:56 2016 +0300
Committer: vozerov-gridgain <vozerov@gridgain.com>
Committed: Tue Aug 23 12:38:56 2016 +0300

----------------------------------------------------------------------
 .../processors/odbc/escape/OdbcParser.java      | 26 +++++++++-----------
 1 file changed, 11 insertions(+), 15 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/d087c782/modules/core/src/main/java/org/apache/ignite/internal/processors/odbc/escape/OdbcParser.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/odbc/escape/OdbcParser.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/odbc/escape/OdbcParser.java
index f4d822a..71999da 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/odbc/escape/OdbcParser.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/odbc/escape/OdbcParser.java
@@ -86,27 +86,23 @@ public class OdbcParser {
                     throw new IgniteException("Malformed escape sequence " +
                         "(closing curly brace without opening curly brace): " + text);
                 else {
-                    if (nested == null) {
-                        // Found sequence without nesting, process it.
-                        String parseRes = parseExpression(text, openPos, curPos - openPos);
+                    String parseRes;
 
-                        if (earlyExit)
-                            return new ParseResult(startPos, curPos - startPos + 1, parseRes);
-                        else
-                            res.append(parseRes);
-                    }
+                    if (nested == null)
+                        // Found sequence without nesting, process it.
+                        parseRes = parseExpression(text, openPos, curPos - openPos);
                     else {
-                        // Process nesting.
+                        // Special case to process nesting.
                         String res0 = appendNested(text, openPos, curPos + 1, nested);
 
-                        String parseRes = parse0(res0, 0, true).res;
-
-                        if (earlyExit)
-                            return new ParseResult(startPos, curPos - startPos + 1, parseRes);
-                        else
-                            res.append(parseRes);
+                        parseRes = parse0(res0, 0, true).res;
                     }
 
+                    if (earlyExit)
+                        return new ParseResult(startPos, curPos - startPos + 1, parseRes);
+                    else
+                        res.append(parseRes);
+
                     openPos = -1;
 
                     plainPos = curPos + 1;


Mime
View raw message