for (cursor = el; cursor->next != NULL; cursor = cursor->next)
{
if (cursor->ed == ed) {
- return false;
+ /* The entry already exists in this list. */
+ return true;
}
}
if (cursor->ed == ed) {
- return false;
+ /* The entry already exists in this list. */
+ return true;
}
el_new = nwrap_entlist_init(ed);
nwrap_pw_global.num = 0;
}
+#if defined(HAVE_SHADOW_H) && defined(HAVE_GETSPNAM)
if (nwrap_sp_global.cache != NULL) {
struct nwrap_cache *c = nwrap_sp_global.cache;
nwrap_sp_global.num = 0;
}
+#endif /* defined(HAVE_SHADOW_H) && defined(HAVE_GETSPNAM) */
if (nwrap_he_global.cache != NULL) {
struct nwrap_cache *c = nwrap_he_global.cache;
nwrap_he_global.num = 0;
}
+ free(user_addrlist.items);
+#ifdef HAVE_GETHOSTBYNAME2
+ free(user_addrlist2.items);
+#endif
+
hdestroy();
NWRAP_UNLOCK_ALL;
}