Skip to content

Commit

Permalink
Map IllegalArgumentException to BackgroundException
Browse files Browse the repository at this point in the history
  • Loading branch information
AliveDevil committed May 14, 2024
1 parent fb98497 commit d55dc96
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
import ch.cyberduck.core.ssl.ThreadLocalHostnameDelegatingTrustManager;
import ch.cyberduck.core.ssl.X509KeyManager;
import ch.cyberduck.core.ssl.X509TrustManager;
import ch.cyberduck.core.worker.DefaultExceptionMappingService;

import org.apache.http.HttpStatus;
import org.apache.http.client.ClientProtocolException;
Expand Down Expand Up @@ -121,6 +122,12 @@ public void test(final Host bookmark) throws BackgroundException {
}
throw new DefaultIOExceptionMappingService().map(e);
}
catch(IllegalArgumentException e) {
if(log.isWarnEnabled()) {
log.warn(String.format("Parsing URI %s: %s", bookmark, e));
}
throw new DefaultExceptionMappingService().map(e);
}
// Ignore
}

Expand Down

0 comments on commit d55dc96

Please sign in to comment.