[PATCH 3/4] Change proxy regex in loader to match python proxy regex (#602712)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Use the exact same regex in both places to take advantage of the
proxy regex unit testing.

Related: rhbz#602712
---
 loader/urls.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/loader/urls.c b/loader/urls.c
index 701f1c5..4366f0c 100644
--- a/loader/urls.c
+++ b/loader/urls.c
@@ -64,7 +64,7 @@ int progress_cb(void *data, double dltotal, double dlnow, double ultotal, double
 
 int splitProxyParam(char *param, char **user, char **password, char **proxy) {
     /* proxy=[protocol://][username[:password]@]host[:port] */
-    char *pattern = "([[:alpha:]]+://)?(([[:alnum:]]+)(:[^:@]+)?@)?([^:]+)(:[[:digit:]]+)?(/.*)?";
+    char *pattern = "([A-Za-z]+://)?(([A-Za-z0-9]+)(:[^:@]+)?@)?([^:/]+)(:[0-9]+)?(/.*)?";
     regex_t re;
     regmatch_t pmatch[NMATCH];
 
-- 
1.7.0.1

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list


[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux