Print this page
5910 libnisdb won't build with modern GCC
@@ -17,12 +17,15 @@
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
+ * Copyright 2015 Gary Mills
* Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
+ *
+ * Copyright 2015 RackTop Systems.
*/
#include <sys/types.h>
#include <time.h>
#include <sys/time.h>
@@ -212,11 +215,11 @@
if (stat != 0) {
(void) mutex_unlock(&table->mapping.enumLock);
logmsg(MSG_NOTIMECHECK, LOG_WARNING,
"%s: Error %d creating new thread; using current one",
myself, stat);
- stat = (int)entriesFromLDAPthread(arg);
+ stat = entriesFromLDAPreal(arg);
return (stat);
}
table->mapping.enumTid = tid;
table->mapping.enumStat = -1;
@@ -255,11 +258,11 @@
}
}
#endif /* FORCE_SYNCHRONOUS */
} else {
(void) mutex_unlock(&table->mapping.enumLock);
- stat = (int)entriesFromLDAPthread(arg);
+ stat = entriesFromLDAPreal(arg);
}
return (stat);
}
@@ -271,11 +274,10 @@
* C++ function.
*/
static void *
entriesFromLDAPthread(void *voidarg) {
__entries_from_ldap_arg_t *arg;
- int stat;
db *dbase;
db_table_desc *tbl = 0;
char *tableName;
arg = (__entries_from_ldap_arg_t *)voidarg;
@@ -309,20 +311,20 @@
#endif /* NISDB_LDAP_DEBUG */
sfree(tableName);
tableName = 0;
}
- stat = entriesFromLDAPreal(arg);
+ (void) entriesFromLDAPreal(arg);
(void) __nis_ulock_db_table(arg->tableName, 1, 0,
"entriesFromLDAPthread");
freeQuery(arg->q);
if (arg->dirObj != 0)
nis_destroy_object(arg->dirObj);
sfree(arg);
- return ((void *)stat);
+ return (NULL);
}
}
int