alexcrichton / alexcrichton/curl-rust

CURLOPT_COOKIEFILE and Easy::cookie_file

未关闭
#636 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
主要语言
Rust
星标
1.1k
派生
259
PR 合并指标
30 天内没有已合并 PR

描述

Hello all,

The libcurl doc for [CURLOPT_COOKIEFILE](https://curl.se/libcurl/c/CURLOPT_COOKIEFILE.html) states that:

> Setting this option to NULL disables the cookie engine and clears the list of files to read cookies from.

I've a use case where an `Easy` handle configures a certain cookie file, and then should be set to null for subsequent request (reusing the same handle).

The actual signature of the `Easy` cookie file method is:

Would the curl crate project accepts a PR that changes the signature to pass a NULL to CURLOPT_COOKIEFILE (changing the `P` parameter to `Option

`):

```rust
pub fn cookie_file>(&mut self, file: Option

) -> Result<(), Error> {
```

The same kind of signature that other methods have:

https://github.com/alexcrichton/curl-rust/blob/14d51cf1f364351456dfd9ab89521242873fb95d/src/easy/handle.rs#L168

I'm asking this question because I've the impression (certainly not real and not a critique at all) that the crate is now only accepting updates to the libcurl binding PR kind.

Thanks a lot for any feedback,

贡献指南

这个仓库没有索引到贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。