strcase: s/strequal/strcasecompare

some more follow-ups to 811a693b80
This commit is contained in:
Daniel Stenberg 2016-10-31 09:37:30 +01:00
Родитель 532491a27c
Коммит 44c53cc38b
3 изменённых файлов: 16 добавлений и 16 удалений

Просмотреть файл

@ -708,16 +708,16 @@ static void _ldap_trace (const char *fmt, ...)
*/ */
static int str2scope (const char *p) static int str2scope (const char *p)
{ {
if(strequal(p, "one")) if(strcasecompare(p, "one"))
return LDAP_SCOPE_ONELEVEL; return LDAP_SCOPE_ONELEVEL;
if(strequal(p, "onetree")) if(strcasecompare(p, "onetree"))
return LDAP_SCOPE_ONELEVEL; return LDAP_SCOPE_ONELEVEL;
if(strequal(p, "base")) if(strcasecompare(p, "base"))
return LDAP_SCOPE_BASE; return LDAP_SCOPE_BASE;
if(strequal(p, "sub")) if(strcasecompare(p, "sub"))
return LDAP_SCOPE_SUBTREE; return LDAP_SCOPE_SUBTREE;
if(strequal(p, "subtree")) if(strcasecompare(p, "subtree"))
return LDAP_SCOPE_SUBTREE; return LDAP_SCOPE_SUBTREE;
return (-1); return (-1);
} }
@ -776,9 +776,9 @@ static int _ldap_url_parse2(const struct connectdata *conn, LDAPURLDesc *ludp)
size_t i; size_t i;
if(!conn->data || if(!conn->data ||
!conn->data->state.path || !conn->data->state.path ||
conn->data->state.path[0] != '/' || conn->data->state.path[0] != '/' ||
!checkprefix("LDAP", conn->data->change.url)) !checkprefix("LDAP", conn->data->change.url))
return LDAP_INVALID_SYNTAX; return LDAP_INVALID_SYNTAX;
ludp->lud_scope = LDAP_SCOPE_BASE; ludp->lud_scope = LDAP_SCOPE_BASE;

Просмотреть файл

@ -27,7 +27,7 @@
#include <curl/curl.h> #include <curl/curl.h>
#include "urldata.h" #include "urldata.h"
#include "strequal.h" #include "strcase.h"
#include "hostcheck.h" #include "hostcheck.h"
#include "vtls/vtls.h" #include "vtls/vtls.h"
#include "sendf.h" #include "sendf.h"

Просмотреть файл

@ -2,7 +2,7 @@
<info> <info>
<keywords> <keywords>
unittest unittest
curl_strequal curl_strcasecompare
</keywords> </keywords>
</info> </info>
@ -16,7 +16,7 @@ none
unittest unittest
</features> </features>
<name> <name>
curl_strequal unit tests curl_strcasecompare unit tests
</name> </name>
<tool> <tool>
unit1301 unit1301