summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 57d32cd)
raw | patch | inline | side by side (parent: 57d32cd)
author | Sebastian Harl <sh@tokkee.org> | |
Tue, 22 Jan 2008 08:34:03 +0000 (09:34 +0100) | ||
committer | Florian Forster <octo@huhu.verplant.org> | |
Tue, 22 Jan 2008 09:46:18 +0000 (10:46 +0100) |
There is no need to initialize curl, if the plugin will not be used anyway.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
src/apache.c | patch | blob | history |
diff --git a/src/apache.c b/src/apache.c
index 2365d1ff15f344f53f8992129fa87dab96880da9..5a3272f8c3485c1498614a603277ef708034ee92 100644 (file)
--- a/src/apache.c
+++ b/src/apache.c
{
static char credentials[1024];
+ if (url == NULL)
+ return (0);
+
if (curl != NULL)
{
curl_easy_cleanup (curl);
curl_easy_setopt (curl, CURLOPT_USERPWD, credentials);
}
- if (url != NULL)
- {
- curl_easy_setopt (curl, CURLOPT_URL, url);
- }
+ curl_easy_setopt (curl, CURLOPT_URL, url);
if (cacert != NULL)
{