Skip to content

Commit

Permalink
Fix Build on Mac OS X - Fixes bug 183
Browse files Browse the repository at this point in the history
  • Loading branch information
dominique.leuenberger@gmail.com committed Aug 27, 2013
1 parent 6bcc831 commit 25cc320
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
3 changes: 2 additions & 1 deletion NEWS
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ New in version <NEXT>
* Fix linking of perl bindings to pthread (Bug #182)
* Correctly detect spidermonky (mozjs185) (Bug #188)
* Stop pxgsettings from segfaulting on exit (Bug #192)
* Fix test #10 (Bug 189)
* Fix test #10 (Bug #189)
* Fix build on Mac OS X (Bug #183)

New in version 0.4.11
==============================
Expand Down
6 changes: 3 additions & 3 deletions libproxy/modules/config_macosx.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ static string capitalize(string str) {

class macosx_config_extension : public config_extension {
public:
vector<url> get_config(const url &url) throw (runtime_error) {
vector<url> get_config(const url &the_url) throw (runtime_error) {
string tmp;
CFDictionaryRef proxies = SCDynamicStoreCopyProxies(NULL);
vector<url> response;
Expand All @@ -136,8 +136,8 @@ class macosx_config_extension : public config_extension {
}

// http:// or socks:// (TODO: gopher:// and rtsp:// ???)
else if ((protocol_url(proxies, toupper(url.get_scheme()), tmp) && url::is_valid(tmp)) ||
(protocol_url(proxies, capitalize(url.get_scheme()), tmp) && url::is_valid(tmp)) ||
else if ((protocol_url(proxies, toupper(the_url.get_scheme()), tmp) && url::is_valid(tmp)) ||
(protocol_url(proxies, capitalize(the_url.get_scheme()), tmp) && url::is_valid(tmp)) ||
(protocol_url(proxies, toupper("http"), tmp) && url::is_valid(tmp)) ||
(protocol_url(proxies, toupper("socks"), tmp) && url::is_valid(tmp))) {
CFRelease(proxies);
Expand Down

0 comments on commit 25cc320

Please sign in to comment.