Fossil SCM
Make proxy setting "system" by default to use http_proxy environment variable. Closer to old behavior and conform with most programs on Unix-like system.
Commit
8f9f2cb7cd2e11b4be1fca90ae83d6cd35aecc263fecf05d7eea704fffd2392d
Parent
e1b51150afaf13a…
2 files changed
+4
-3
+1
-1
M
src/db.c
+4
-3
| --- src/db.c | ||
| +++ src/db.c | ||
| @@ -4455,13 +4455,14 @@ | ||
| 4455 | 4455 | ** SETTING: pgp-command width=40 sensitive |
| 4456 | 4456 | ** Command used to clear-sign manifests at check-in. |
| 4457 | 4457 | ** Default value is "gpg --clearsign -o" |
| 4458 | 4458 | */ |
| 4459 | 4459 | /* |
| 4460 | -** SETTING: proxy width=32 default=off | |
| 4461 | -** URL of the HTTP proxy. If "system", the "http_proxy" environment variable is | |
| 4462 | -** consulted. If undefined or "off", a direct HTTP connection is used. | |
| 4460 | +** SETTING: proxy width=32 default=system | |
| 4461 | +** URL of the HTTP proxy. If undefined or "system", the "http_proxy" | |
| 4462 | +** environment variable is consulted. If "off", a direct HTTP connection is | |
| 4463 | +** used. | |
| 4463 | 4464 | */ |
| 4464 | 4465 | /* |
| 4465 | 4466 | ** SETTING: redirect-to-https default=0 width=-1 |
| 4466 | 4467 | ** Specifies whether or not to redirect http:// requests to |
| 4467 | 4468 | ** https:// URIs. A value of 0 (the default) means not to |
| 4468 | 4469 |
| --- src/db.c | |
| +++ src/db.c | |
| @@ -4455,13 +4455,14 @@ | |
| 4455 | ** SETTING: pgp-command width=40 sensitive |
| 4456 | ** Command used to clear-sign manifests at check-in. |
| 4457 | ** Default value is "gpg --clearsign -o" |
| 4458 | */ |
| 4459 | /* |
| 4460 | ** SETTING: proxy width=32 default=off |
| 4461 | ** URL of the HTTP proxy. If "system", the "http_proxy" environment variable is |
| 4462 | ** consulted. If undefined or "off", a direct HTTP connection is used. |
| 4463 | */ |
| 4464 | /* |
| 4465 | ** SETTING: redirect-to-https default=0 width=-1 |
| 4466 | ** Specifies whether or not to redirect http:// requests to |
| 4467 | ** https:// URIs. A value of 0 (the default) means not to |
| 4468 |
| --- src/db.c | |
| +++ src/db.c | |
| @@ -4455,13 +4455,14 @@ | |
| 4455 | ** SETTING: pgp-command width=40 sensitive |
| 4456 | ** Command used to clear-sign manifests at check-in. |
| 4457 | ** Default value is "gpg --clearsign -o" |
| 4458 | */ |
| 4459 | /* |
| 4460 | ** SETTING: proxy width=32 default=system |
| 4461 | ** URL of the HTTP proxy. If undefined or "system", the "http_proxy" |
| 4462 | ** environment variable is consulted. If "off", a direct HTTP connection is |
| 4463 | ** used. |
| 4464 | */ |
| 4465 | /* |
| 4466 | ** SETTING: redirect-to-https default=0 width=-1 |
| 4467 | ** Specifies whether or not to redirect http:// requests to |
| 4468 | ** https:// URIs. A value of 0 (the default) means not to |
| 4469 |
+1
-1
| --- src/url.c | ||
| +++ src/url.c | ||
| @@ -560,11 +560,11 @@ | ||
| 560 | 560 | */ |
| 561 | 561 | void url_enable_proxy(const char *zMsg){ |
| 562 | 562 | const char *zProxy; |
| 563 | 563 | zProxy = zProxyOpt; |
| 564 | 564 | if( zProxy==0 ){ |
| 565 | - zProxy = db_get("proxy", 0); | |
| 565 | + zProxy = db_get("proxy", "system"); | |
| 566 | 566 | if( fossil_strcmp(zProxy, "system")==0 ){ |
| 567 | 567 | zProxy = fossil_getenv("http_proxy"); |
| 568 | 568 | } |
| 569 | 569 | } |
| 570 | 570 | if( zProxy && zProxy[0] && !is_false(zProxy) |
| 571 | 571 |
| --- src/url.c | |
| +++ src/url.c | |
| @@ -560,11 +560,11 @@ | |
| 560 | */ |
| 561 | void url_enable_proxy(const char *zMsg){ |
| 562 | const char *zProxy; |
| 563 | zProxy = zProxyOpt; |
| 564 | if( zProxy==0 ){ |
| 565 | zProxy = db_get("proxy", 0); |
| 566 | if( fossil_strcmp(zProxy, "system")==0 ){ |
| 567 | zProxy = fossil_getenv("http_proxy"); |
| 568 | } |
| 569 | } |
| 570 | if( zProxy && zProxy[0] && !is_false(zProxy) |
| 571 |
| --- src/url.c | |
| +++ src/url.c | |
| @@ -560,11 +560,11 @@ | |
| 560 | */ |
| 561 | void url_enable_proxy(const char *zMsg){ |
| 562 | const char *zProxy; |
| 563 | zProxy = zProxyOpt; |
| 564 | if( zProxy==0 ){ |
| 565 | zProxy = db_get("proxy", "system"); |
| 566 | if( fossil_strcmp(zProxy, "system")==0 ){ |
| 567 | zProxy = fossil_getenv("http_proxy"); |
| 568 | } |
| 569 | } |
| 570 | if( zProxy && zProxy[0] && !is_false(zProxy) |
| 571 |