Skip to content

http_set_curlopt() works one time #76

Closed
@ghost

Description

I am using the latest release 1.2.3.

I noticed today that the http extension does not save the CURL options permanently (well, permanently within the session). I have entered a proxy with port and access data. But on the second call, an error message like host not resolved (from a company intranet) appears.

I can't exactly recreate the initial situation, but it's basically similar. I'm setting a proxy that doesn't exist. Then I expect on every call an error message that the proxy refuses the connection, but the error message only comes once:

jotpe=> select http_set_curlopt('CURLOPT_PROXY', '127.0.0.1');
 http_set_curlopt 
------------------
 t
(1 Zeile)

jotpe=> SELECT content FROM http_get('http://httpbin.org/ip');
FEHLER:  Failed to connect to 127.0.0.1 port 1080: Verbindungsaufbau abgelehnt
jotpe=> SELECT content FROM http_get('http://httpbin.org/ip');
          content           
----------------------------
 {"origin":"re.pl.ac.ed"}+
 
(1 Zeile)

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions