s3: auth.krb5ccname and auth.unix_username are both fstrings
authorVolker Lendecke <vl@samba.org>
Fri, 10 Sep 2010 10:49:32 +0000 (12:49 +0200)
committerVolker Lendecke <vl@samba.org>
Fri, 10 Sep 2010 17:52:18 +0000 (10:52 -0700)
There's no point in checking for != NULL

nsswitch/libwbclient/wbc_pam.c

index 50524d2169b658d2a77752867c006f3da5855dcf..41c1142d4d15c80829abbf67f8bb942767349f71 100644 (file)
@@ -313,8 +313,7 @@ static wbcErr wbc_create_logon_info(struct winbindd_response *resp,
        wbc_status = wbc_create_auth_info(resp, &i->info);
        BAIL_ON_WBC_ERROR(wbc_status);
 
-       if (resp->data.auth.krb5ccname &&
-           strlen(resp->data.auth.krb5ccname)) {
+       if (resp->data.auth.krb5ccname[0] != '\0') {
                wbc_status = wbcAddNamedBlob(&i->num_blobs,
                                             &i->blobs,
                                             "krb5ccname",
@@ -324,8 +323,7 @@ static wbcErr wbc_create_logon_info(struct winbindd_response *resp,
                BAIL_ON_WBC_ERROR(wbc_status);
        }
 
-       if (resp->data.auth.unix_username &&
-           strlen(resp->data.auth.unix_username)) {
+       if (resp->data.auth.unix_username[0] != '\0') {
                wbc_status = wbcAddNamedBlob(&i->num_blobs,
                                             &i->blobs,
                                             "unix_username",