Explorar o código

fix Windows build issues

Rich Megginson %!s(int64=21) %!d(string=hai) anos
pai
achega
a71ecb02ba
Modificáronse 2 ficheiros con 3 adicións e 1 borrados
  1. 1 0
      ldap/servers/plugins/uiduniq/Makefile
  2. 2 1
      ldap/servers/slapd/schema.c

+ 1 - 0
ldap/servers/plugins/uiduniq/Makefile

@@ -54,6 +54,7 @@ endif
 
 ifeq ($(ARCH), WINNT)
 DLL_LDFLAGS += -def:"./libuiduniq.def"
+EXTRA_LIBS += $(NSPRLINK)
 endif # WINNT
 
 ifeq ($(ARCH), AIX)

+ 2 - 1
ldap/servers/slapd/schema.c

@@ -4471,7 +4471,8 @@ schema_create_errormsg(
 		if ( NULL != name ) {
 			rc = PR_snprintf( errorbuf, errorbufsize, prefix, name );
 		}
-		if ( (rc >= 0) && (rc < errorbufsize) ) {
+		/* ok to cast here because rc is positive */
+		if ( (rc >= 0) && ((size_t)rc < errorbufsize) ) {
 			(void)PR_vsnprintf( errorbuf + rc, errorbufsize - rc, fmt, ap );
 		}
 		va_end( ap );