How do i turnoff WRITEFUNCTION and WRITEDATA ?
using pycurl i have a class call curlUtil. In it i have pageAsString(self, url) which returns a string. To do this i setopt WRITEFUNCTION. Now in downloadFile(self, url, fn, overwrite=0) i do an open and self.c.setopt(pycurl.WRITEFUNCTION, 0) which cause problems. int is not a valid arguement. I then assumed WRITEDATA would overwrite the value or there would be a NOWRITEFUNCTION commend. NOWRITEFUNCTION didnt exist so i just used WRITEDATA and python crashed. I wrote a quick func called reboot() which closes curl, opens it again and calls reset to put it in the default state. i call it in both pageAsString and downloadFile and there is no problem at all. But, i dont want to reinitialize curl. There might be some special options i set. How do i turnoff WRITEFUNCTION and WRITEDATA ?
-edit- a day later and i still have no idea how to solve this with something other then my current destory/create hack