summaryrefslogtreecommitdiff
path: root/0001-Use-system-copy-of-effective_tld_names.dat.patch
diff options
context:
space:
mode:
authorCoprDistGit <infra@openeuler.org>2024-08-05 02:40:58 +0000
committerCoprDistGit <infra@openeuler.org>2024-08-05 02:40:58 +0000
commit81ea2941950d6c1d68fbffbff81a847962d5ed53 (patch)
treed29cc81e970a4a17dbaf380f0b5c4ca4f6ae47ef /0001-Use-system-copy-of-effective_tld_names.dat.patch
parentd74ee43fcb3346b708e2c567c0215efb24113733 (diff)
automatic import of httpcomponents-clientopeneuler24.03_LTS
Diffstat (limited to '0001-Use-system-copy-of-effective_tld_names.dat.patch')
-rw-r--r--0001-Use-system-copy-of-effective_tld_names.dat.patch31
1 files changed, 31 insertions, 0 deletions
diff --git a/0001-Use-system-copy-of-effective_tld_names.dat.patch b/0001-Use-system-copy-of-effective_tld_names.dat.patch
new file mode 100644
index 0000000..e4e0f7c
--- /dev/null
+++ b/0001-Use-system-copy-of-effective_tld_names.dat.patch
@@ -0,0 +1,31 @@
+From d9f08c36a39b035ec70a37cb6aac5f980cc57054 Mon Sep 17 00:00:00 2001
+From: Mikolaj Izdebski <mizdebsk@redhat.com>
+Date: Tue, 20 Jan 2015 16:04:31 +0100
+Subject: [PATCH 1/2] Use system copy of effective_tld_names.dat
+
+---
+ .../apache/http/conn/util/PublicSuffixMatcherLoader.java | 7 +++----
+ 1 file changed, 3 insertions(+), 4 deletions(-)
+
+diff --git a/httpclient/src/main/java/org/apache/http/conn/util/PublicSuffixMatcherLoader.java b/httpclient/src/main/java/org/apache/http/conn/util/PublicSuffixMatcherLoader.java
+index 8783c5b..c858220 100644
+--- a/httpclient/src/main/java/org/apache/http/conn/util/PublicSuffixMatcherLoader.java
++++ b/httpclient/src/main/java/org/apache/http/conn/util/PublicSuffixMatcherLoader.java
+@@ -82,11 +82,10 @@ public final class PublicSuffixMatcherLoader {
+ if (DEFAULT_INSTANCE == null) {
+ synchronized (PublicSuffixMatcherLoader.class) {
+ if (DEFAULT_INSTANCE == null){
+- final URL url = PublicSuffixMatcherLoader.class.getResource(
+- "/mozilla/public-suffix-list.txt");
+- if (url != null) {
++ final File file = new File("/usr/share/publicsuffix/effective_tld_names.dat");
++ if (file.exists()) {
+ try {
+- DEFAULT_INSTANCE = load(url);
++ DEFAULT_INSTANCE = load(file);
+ } catch (final IOException ex) {
+ // Should never happen
+ final Log log = LogFactory.getLog(PublicSuffixMatcherLoader.class);
+--
+2.19.1
+