anonymous2ch / libproxy

Automatically exported from code.google.com/p/libproxy
GNU Lesser General Public License v2.1
0 stars 0 forks source link

If gconf's value is an empty list, pxgconf will make /usr/bin/proxy wait forever #164

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
Probably there are other better ways to reproduce it, though:

1. set up things to use config_gnome and set some secure proxy host so that 
/usr/bin/proxy can detect and return it.
2. set /system/http_proxy/ignore_hosts an empty list
3. run proxy https://www.google.com

What is the expected output? What do you see instead?

Proxy eventually exit, returning the result of the query.

Instead

Proxy is hanging forever apparently waiting for input.

In detail, using this cmdline:
$ /usr/libexec/pxgconf /system/proxy/mode /system/http_proxy/use_authentication 
/system/http_proxy/authentication_password 
/system/http_proxy/authentication_user /system/proxy/autoconfig_url 
/system/http_proxy/ignore_hosts /system/http_proxy/host /system/http_proxy/port 
/system/proxy/ftp_host /system/proxy/ftp_port /system/proxy/secure_host 
/system/proxy/secure_port /system/proxy/socks_host /system/proxy/socks_port 
/system/http_proxy/use_same_proxy

Output:

/system/proxy/mode  manual
/system/http_proxy/use_authentication
/system/http_proxy/authentication_password
/system/http_proxy/authentication_user
/system/proxy/autoconfig_url    
/system/http_proxy/ignore_hosts /system/http_proxy/host localhost
/system/http_proxy/port 0
/system/proxy/ftp_host  
/system/proxy/ftp_port  0
/system/proxy/secure_host   172.22.64.110
/system/proxy/secure_port   4242
/system/proxy/socks_host    
/system/proxy/socks_port    0
/system/http_proxy/use_same_proxy   false

Note that ignore_hosts line is badly formatted, this because in pxgconf.cpp 
print_value() does not add @prefix when the list is empty.

Fixing it, will make /usr/bin/proxy behave in the expected way.

Patch attached.

Using 0.4.7 (tarball from site)

Original issue reported on code.google.com by c.alfar...@gmail.com on 28 Jul 2011 at 6:17

Attachments:

GoogleCodeExporter commented 9 years ago
Upstream, will be in 0.4.8.

Original comment by nicolas.dufresne@gmail.com on 28 Jul 2011 at 7:35

GoogleCodeExporter commented 9 years ago

Original comment by nicolas.dufresne@gmail.com on 28 Jul 2011 at 7:35