Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

setOpt() const parameters #140

Open
m5k8 opened this issue Jan 17, 2022 · 1 comment
Open

setOpt() const parameters #140

m5k8 opened this issue Jan 17, 2022 · 1 comment

Comments

@m5k8
Copy link

m5k8 commented Jan 17, 2022

const parameters passed to setOpt(), let's say:

request.setOpt<curlpp::options::UserAgent>(some_const_user_agent_str);

get converted to (void *), here - OptionSetter.inl:44:

handle->option(optionType, (void *)value.c_str());

and this cast generates compiler warning. It would be nice if it compiled cleanly.

@sgallou
Copy link
Collaborator

sgallou commented Jan 18, 2022

Hi,
could you provide a PR, please ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants