aboutsummaryrefslogtreecommitdiffstats
path: root/org.aspectj.ajdt.core
diff options
context:
space:
mode:
authorAndy Clement <aclement@pivotal.io>2018-03-12 08:37:38 -0700
committerAndy Clement <aclement@pivotal.io>2018-03-12 08:37:38 -0700
commitf8d82161e3b5c5ddcc6ec16540c3e1ab637bd04c (patch)
treee76e66610a0797b3dbb354e33d02943970aa33f5 /org.aspectj.ajdt.core
parentd575da7bbb675d6d45c1c319f12a4bb0f2cac20e (diff)
downloadaspectj-f8d82161e3b5c5ddcc6ec16540c3e1ab637bd04c.tar.gz
aspectj-f8d82161e3b5c5ddcc6ec16540c3e1ab637bd04c.zip
Add checking for env variable ASPECTJ_OPTS in addition to sys prop
Diffstat (limited to 'org.aspectj.ajdt.core')
-rw-r--r--org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/ConfigParser.java10
1 files changed, 9 insertions, 1 deletions
diff --git a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/ConfigParser.java b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/ConfigParser.java
index 4c7873df0..1bbd3327b 100644
--- a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/ConfigParser.java
+++ b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/ConfigParser.java
@@ -45,7 +45,15 @@ public class ConfigParser {
for (int i = 0; i < argsArray.length; i++) {
args.add(new Arg(argsArray[i], location));
}
- String aspectjOptions = System.getProperty("ASPECTJ_OPTS");
+ String aspectjOptions = null;
+ try {
+ aspectjOptions = System.getenv("ASPECTJ_OPTS");
+ if (aspectjOptions == null) {
+ aspectjOptions = System.getProperty("ASPECTJ_OPTS");
+ }
+ } catch (Throwable t) {
+ aspectjOptions = null;
+ }
if (aspectjOptions != null) {
StringTokenizer st = new StringTokenizer(aspectjOptions);
while (st.hasMoreElements()) {