Index: snmpd.c
===================================================================
--- snmpd.c	(revision 16592)
+++ snmpd.c	(working copy)
@@ -949,8 +949,10 @@
     gid = netsnmp_ds_get_int(NETSNMP_DS_APPLICATION_ID, 
 			     NETSNMP_DS_AGENT_GROUPID);
     
+#if !defined (mingw32)
     if ( uid != 0 || gid != 0 )
         chown( cptr, uid, gid );
+#endif
 
 #ifdef HAVE_SETGID
     if ((gid = netsnmp_ds_get_int(NETSNMP_DS_APPLICATION_ID, 
Index: mibgroup/disman/schedule/schedCore.c
===================================================================
--- mibgroup/disman/schedule/schedCore.c	(revision 16592)
+++ mibgroup/disman/schedule/schedCore.c	(working copy)
@@ -239,6 +239,20 @@
 }
 
 
+#if defined (mingw32)
+struct tm *
+localtime_r(const time_t *timep, struct tm *result) {
+    struct tm *tmp;
+
+    tmp = localtime( timep );
+    if ( tmp && result ) {
+        memcpy( result, tmp, sizeof(struct tm));
+    }
+
+    return (tmp ? result : NULL );
+}
+#endif
+
 /*
  * determine the time for the next scheduled action of a given entry
  */
