Search code examples
pythonpycurl

How to reset HTTPHEADERs in pycurl object?


I've set some additional headers using

c.setopt(self.c.HTTPHEADER, ['Accept: */*', ..., ...])

Now what I want is to reset/clear that headers without destroying pycurl object or closing session.


Solution

  • You can do this easily with:

    c.reset()