mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
fix http
This commit is contained in:
parent
36d343e931
commit
52f93ae45f
@ -24,7 +24,7 @@ fn download_cb(ptr voidptr, size, nmemb size_t, userp voidptr) int {
|
||||
return written
|
||||
}
|
||||
|
||||
fn download_file_with_progress(url, out string, cb, cb_finished downloadfn) {
|
||||
fn download_file_with_progress(url, out string, cb downloadfn, cb_finished download_finished_fn) {
|
||||
curl := C.curl_easy_init()
|
||||
if isnil(curl) {
|
||||
return
|
||||
|
@ -60,7 +60,7 @@ pub fn new_request(typ, _url, _data string) *Request {
|
||||
data: _data
|
||||
ws_func: 0
|
||||
user_ptr: 0
|
||||
headers: new_map(0, sizeof(string))
|
||||
headers: map[string]string{}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -93,7 +93,7 @@ fn (req &Request) do() Response {
|
||||
}
|
||||
// header chunk
|
||||
hchunk := MemoryStruct {
|
||||
ws_func: 0
|
||||
ws_func: foo
|
||||
user_ptr: 0
|
||||
}
|
||||
// init curl
|
||||
|
Loading…
Reference in New Issue
Block a user