Comments (2)
I was able to fix this issue locally but not sure if this is how you would want to fix it. Below is the patch for the changes I made if you want to use them ...
From 897f595008f18798503e6a339c55c91c4455bb9d Mon Sep 17 00:00:00 2001
Date: Wed, 15 Jan 2014 08:40:21 -0500
Subject: [PATCH] Fixing logical and/or statements
---
src/main/java/org/kohsuke/groovy/sandbox/impl/Ops.java | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/main/java/org/kohsuke/groovy/sandbox/impl/Ops.java b/src/main/java/org/kohsuke/groovy/sandbox/impl/Ops.java
index 57b3f02..e8fcc62 100644
--- a/src/main/java/org/kohsuke/groovy/sandbox/impl/Ops.java
+++ b/src/main/java/org/kohsuke/groovy/sandbox/impl/Ops.java
@@ -64,6 +64,8 @@ public class Ops {
b.put(BITWISE_OR,"or");
b.put(BITWISE_AND,"and");
b.put(BITWISE_XOR,"xor");
+ b.put(LOGICAL_OR,"or");
+ b.put(LOGICAL_AND,"and");
b.put(LEFT_SHIFT,"leftShift");
b.put(RIGHT_SHIFT,"rightShift");
b.put(RIGHT_SHIFT_UNSIGNED,"rightShiftUnsigned");
--
1.8.3.4 (Apple Git-47)
from groovy-sandbox.
I've fixed this issue. The patch is actually incorrect because the "or" method is for overloading bitwise-or, which is not the same thing as logical or.
from groovy-sandbox.
Related Issues (20)
- Static type checking error in sandbox-transformed code HOT 1
- Is this package now supported in the spring environment HOT 2
- State of groovy-2.4.4 branch? HOT 4
- Prefix/postfix increment operators broken within closures HOT 2
- Sandbox ignoring Owners and Delegates of nested Closures.
- Publish 1.16 on maven central HOT 2
- Add support for tuples
- filter of sandbox is inactive HOT 2
- Stack overflow on long chained method calls
- Release 1.20 doesn't seem to be available in Maven Central Repository HOT 2
- Arbitrary file read HOT 1
- Sandbox Escape HOT 1
- It's not obvious that https://repo.jenkins-ci.org/public/ needs to be configured as a repository HOT 2
- Missing property exception for closure parameter when used in while statement HOT 5
- add groovy 3 support HOT 1
- StackOverflowError on a class method call HOT 2
- Why not update jar on mvnrepository HOT 1
- ArrayIndexOutOfBoundsException in GroovyCallSiteSelector.isIllegalCallToSyntheticConstructor HOT 4
- class: org/kohsuke/groovy/sandbox/SandboxTransformer, method: super$2$needSortedInput signature: ()Z) Illegal use of nonvirtual function call
- BUG! exception in phase 'canonicalization': NPE in SandboxTransformer HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from groovy-sandbox.