aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorakozak2011-11-24 09:28:39 (EST)
committerWinston Prakash2011-12-01 20:47:28 (EST)
commit09029c89f30bdb0a58243e29a05bfc479fe5acd6 (patch)
treee93678dc0ad98f27240ae24359f1641a84bf3503
parent3c64aa75c11962a73870600bf1a571a6ca6efc5b (diff)
downloadorg.eclipse.hudson.core-09029c89f30bdb0a58243e29a05bfc479fe5acd6.zip
org.eclipse.hudson.core-09029c89f30bdb0a58243e29a05bfc479fe5acd6.tar.gz
org.eclipse.hudson.core-09029c89f30bdb0a58243e29a05bfc479fe5acd6.tar.bz2
HUDSON-9064: avoid UnsupportedOperationException on JBoss5 by using url.openConnection() when there is no proxy configuration
Signed-off-by: Winston Prakash <winston.prakash@gmail.com>
-rw-r--r--hudson-core/src/main/java/hudson/ProxyConfiguration.java2
-rw-r--r--hudson-core/src/main/java/hudson/util/CascadingUtil.java4
2 files changed, 3 insertions, 3 deletions
diff --git a/hudson-core/src/main/java/hudson/ProxyConfiguration.java b/hudson-core/src/main/java/hudson/ProxyConfiguration.java
index 83f1d4a..8f45d7a 100644
--- a/hudson-core/src/main/java/hudson/ProxyConfiguration.java
+++ b/hudson-core/src/main/java/hudson/ProxyConfiguration.java
@@ -129,7 +129,7 @@ public final class ProxyConfiguration implements Saveable {
if(proxyConfig == null){
- return url.openConnection(Proxy.NO_PROXY);
+ return url.openConnection();
}
if (proxyConfig.noProxyFor != null){
diff --git a/hudson-core/src/main/java/hudson/util/CascadingUtil.java b/hudson-core/src/main/java/hudson/util/CascadingUtil.java
index 85772e1..fc72a72 100644
--- a/hudson-core/src/main/java/hudson/util/CascadingUtil.java
+++ b/hudson-core/src/main/java/hudson/util/CascadingUtil.java
@@ -445,7 +445,7 @@ public class CascadingUtil {
if (null != cascadingChildrenNames) {
for (String childName : cascadingChildrenNames) {
Job childJob = (Job) Hudson.getInstance().getItem(childName);
- if (StringUtils.equals(job.getName(), childJob.getCascadingProjectName())) {
+ if (null != childJob && StringUtils.equals(job.getName(), childJob.getCascadingProjectName())) {
TriggerProjectProperty childProperty = CascadingUtil.getTriggerProjectProperty(childJob, key);
if (!childProperty.isOverridden()) {
setChildrenTrigger(childJob, descriptor, key, req, json);
@@ -485,7 +485,7 @@ public class CascadingUtil {
for (String childName : cascadingChildrenNames) {
AbstractProject childJob = (AbstractProject) Hudson.getInstance().getItem(childName);
//Check only direct children in order to avoid deep checking for properties overridden properties.
- if (StringUtils.equals(job.getName(), childJob.getCascadingProjectName())) {
+ if (null != childJob && StringUtils.equals(job.getName(), childJob.getCascadingProjectName())) {
CopyOnWriteListProjectProperty childProperty = getCopyOnWriteListProjectProperty(childJob, key);
//If child value is equal to parent - mark this value as unmodified.
if (!projectProperty.allowOverrideValue(childProperty.getValue(), pdProperties)) {