41 Value vurl = pop_value(vm);
48 FunCurlBuf
buf = {NULL, 0};
49 CURL *h = curl_easy_init();
55 curl_easy_setopt(h, CURLOPT_URL, url);
56 curl_easy_setopt(h, CURLOPT_FOLLOWLOCATION, 1L);
57 curl_easy_setopt(h, CURLOPT_WRITEFUNCTION, fun_curl_write_cb);
58 curl_easy_setopt(h, CURLOPT_WRITEDATA, &
buf);
59 CURLcode
rc = curl_easy_perform(h);
push_value(vm, make_string(""))
Tagged union representing a Fun value.
Value make_string(const char *s)
Construct a string Value by duplicating the given C string.
char * value_to_string_alloc(const Value *v)
Allocate a printable C string for a Value.