CURLMOPT_PUSHDATA - Online Linux Manual PageSection : 3
Updated : November 04, 2020
Source : libcurl 7.82.0
Note : curl_multi_setopt options

NAMECURLMOPT_PUSHDATA − pointer to pass to push callback

SYNOPSIS#include <curl/curl.h> CURLMcode curl_multi_setopt(CURLM *handle, CURLMOPT_PUSHDATA, void *pointer);

DESCRIPTIONSet pointer to pass as the last argument to the CURLMOPT_PUSHFUNCTION(3) callback. The pointer will not be touched or used by libcurl itself, only passed on to the callback function.

DEFAULTNULL

PROTOCOLSHTTP(S)

EXAMPLE/* only allow pushes for file names starting with "push-" */ int push_callback(CURL *parent, CURL *easy, size_t num_headers, struct curl_pushheaders *headers, void *userp) { char *headp; int *transfers = (int *)userp; FILE *out; headp = curl_pushheader_byname(headers, ":path"); if(headp && !strncmp(headp, "/push-", 6)) { fprintf(stderr, "The PATH is %s\n", headp); /* save the push here */ out = fopen("pushed-stream", "wb"); /* write to this file */ curl_easy_setopt(easy, CURLOPT_WRITEDATA, out); (*transfers)++; /* one more */ return CURL_PUSH_OK; } return CURL_PUSH_DENY; } curl_multi_setopt(multi, CURLMOPT_PUSHFUNCTION, push_callback); curl_multi_setopt(multi, CURLMOPT_PUSHDATA, &counter);

AVAILABILITYAdded in 7.44.0

RETURN VALUEReturns CURLM_OK if the option is supported, and CURLM_UNKNOWN_OPTION if not.

SEE ALSOCURLMOPT_PUSHFUNCTION(3), CURLMOPT_PIPELINING (3)," CURLOPT_PIPEWAIT(3)," RFC7540
0
Johanes Gumabo
Data Size   :   5,919 byte
man-CURLMOPT_PUSHDATA.3Build   :   2024-12-29, 07:25   :  
Visitor Screen   :   x
Visitor Counter ( page / site )   :   7 / 256,914
Visitor ID   :     :  
Visitor IP   :   3.145.69.65   :  
Visitor Provider   :   AMAZON-02   :  
Provider Position ( lat x lon )   :   39.962500 x -83.006100   :   x
Provider Accuracy Radius ( km )   :   1000   :  
Provider City   :   Columbus   :  
Provider Province   :   Ohio ,   :   ,
Provider Country   :   United States   :  
Provider Continent   :   North America   :  
Visitor Recorder   :   Version   :  
Visitor Recorder   :   Library   :  
Online Linux Manual Page   :   Version   :   Online Linux Manual Page - Fedora.40 - march=x86-64 - mtune=generic - 24.12.29
Online Linux Manual Page   :   Library   :   lib_c - 24.10.03 - march=x86-64 - mtune=generic - Fedora.40
Online Linux Manual Page   :   Library   :   lib_m - 24.10.03 - march=x86-64 - mtune=generic - Fedora.40
Data Base   :   Version   :   Online Linux Manual Page Database - 24.04.13 - march=x86-64 - mtune=generic - fedora-38
Data Base   :   Library   :   lib_c - 23.02.07 - march=x86-64 - mtune=generic - fedora.36

Very long time ago, I have the best tutor, Wenzel Svojanovsky . If someone knows the email address of Wenzel Svojanovsky , please send an email to johanes_gumabo@yahoo.co.id .
If error, please print screen and send to johanes_gumabo@yahoo.co.id
Under development. Support me via PayPal.

ERROR : Need New Coding :         (rof_nr_x|149|CURLMOPT_PUSHDATA.3|55|\n", headp);| fprintf(stderr, "The PATH is %s\\n", headp); )