这个声明意味着什么?结构 Curl_easy *curl_easy_init(void)
struct Curl_easy *curl_easy_init(void)
{
CURLcode result;
struct Curl_easy *data;
/* Make sure we inited the global SSL stuff */
if(!initialized) {
result = curl_global_init(CURL_GLOBAL_DEFAULT);
if(result) {
/* something in the global init failed, return nothing */
DEBUGF(fprintf(stderr, "Error: curl_global_init failed\n"));
return NULL;
}
}
/* We use curl_open() with undefined URL so far */
result = Curl_open(&data);
if(result) {
DEBUGF(fprintf(stderr, "Error: Curl_open failed\n"));
return NULL;
}
return data;
}
struct Curl_easy *curl_easy_init(void){}
这个声明是什么意思?我可以用谷歌搜索有关此内容的任何合适的关键字吗?我尝试过函数指针结构、结构指针等......
struct Curl_easy *curl_easy_init(void)
{
CURLcode result;
struct Curl_easy *data;
/* Make sure we inited the global SSL stuff */
if(!initialized) {
result = curl_global_init(CURL_GLOBAL_DEFAULT);
if(result) {
/* something in the global init failed, return nothing */
DEBUGF(fprintf(stderr, "Error: curl_global_init failed\n"));
return NULL;
}
}
/* We use curl_open() with undefined URL so far */
result = Curl_open(&data);
if(result) {
DEBUGF(fprintf(stderr, "Error: Curl_open failed\n"));
return NULL;
}
return data;
}
struct Curl_easy *curl_easy_init(void){}
What does this declaration means? Is there any proper keyword can I google about this? I tried Function Pointer Struct, Struct pointer, etc....
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这
是一个名为
curl_easy_init
的函数声明,该函数具有指针返回类型struct Curl_easy *
并且没有参数。如果成功,函数将返回
函数内声明的更新后的指针。否则该函数返回
NULL
。This
is a declaration of a function with the name
curl_easy_init
that has the pointer return typestruct Curl_easy *
and no parameters.In case of success the function returns the updated pointer
declared within the function. Otherwise the function returns
NULL
.