@@ -1827,7 +1827,6 @@ nsdb_ping_s(const char *hostname, const unsigned short port,
retval = nsdb_new_nsdb(hostname, port, &host);
if (retval != FEDFS_OK)
return retval;
- host->fn_sectype = FEDFS_SEC_NONE;
retval = nsdb_open_nsdb(host, NULL, NULL, ldap_err);
if (retval != FEDFS_OK)
@@ -483,6 +483,7 @@ nsdb_new_nsdb(const char *hostname, const unsigned long port, nsdb_t *host)
memset(*host, 0, sizeof(**host));
(*host)->fn_hostname = hostname_tmp;
(*host)->fn_port = port_tmp;
+ (*host)->fn_sectype = FEDFS_SEC_NONE;
return FEDFS_OK;
}
API clean up: Initialize the sectype field in an obvious place that others may re-use reliably. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> --- src/libnsdb/fileserver.c | 1 - src/libnsdb/nsdb.c | 1 + 2 files changed, 1 insertions(+), 1 deletions(-)