aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSteve Holme <steve_holme@hotmail.com>2014-02-06 19:43:50 +0000
committerSteve Holme <steve_holme@hotmail.com>2014-02-06 19:50:32 +0000
commit456169f9e55dfe376e353a4e144402444c1e5578 (patch)
treea497c01283c7ea8e5a50d30458c812091587e5af /src
parentdd97828df70344c0cda642135c2b35756d9568c0 (diff)
tool_operate: Moved list SSL engines code into operate()
Diffstat (limited to 'src')
-rw-r--r--src/tool_operate.c18
1 files changed, 8 insertions, 10 deletions
diff --git a/src/tool_operate.c b/src/tool_operate.c
index 0a867244f..5c1ea5034 100644
--- a/src/tool_operate.c
+++ b/src/tool_operate.c
@@ -247,7 +247,7 @@ static int operate_do(struct Configurable *config, int argc,
goto quit_curl;
}
- if((!config->url_list || !config->url_list->url) && !config->list_engines) {
+ if(!config->url_list || !config->url_list->url) {
helpf(config->errors, "no URL specified!\n");
res = CURLE_FAILED_INIT;
goto quit_curl;
@@ -353,15 +353,6 @@ static int operate_do(struct Configurable *config, int argc,
}
#endif
- if(config->list_engines) {
- struct curl_slist *engines = NULL;
- curl_easy_getinfo(curl, CURLINFO_SSL_ENGINES, &engines);
- list_engines(engines);
- curl_slist_free_all(engines);
- res = CURLE_OK;
- goto quit_curl;
- }
-
/* Single header file for all URLs */
if(config->headerfile) {
/* open file for output: */
@@ -1853,6 +1844,13 @@ int operate(struct Configurable *config, int argc, argv_item_t argv[])
else
result = CURLE_OK;
}
+ /* Check if we were asked to list the SSL engines */
+ else if(config->list_engines) {
+ struct curl_slist *engines = NULL;
+ curl_easy_getinfo(config->easy, CURLINFO_SSL_ENGINES, &engines);
+ list_engines(engines);
+ curl_slist_free_all(engines);
+ }
/* Perform the main operation */
else
result = operate_do(config, argc, argv);