small changes to get coreclr building on FreeBSD again (#14964)
authorTomas Weinfurt <tweinfurt@yahoo.com>
Tue, 14 Nov 2017 21:44:25 +0000 (13:44 -0800)
committerJan Vorlicek <janvorli@microsoft.com>
Tue, 14 Nov 2017 21:44:25 +0000 (22:44 +0100)
src/gc/handletable.cpp
src/gc/handletablescan.cpp
src/gc/unix/cgroup.cpp

index 4942f01..64d51d1 100644 (file)
@@ -561,7 +561,7 @@ uintptr_t HndCompareExchangeHandleExtraInfo(OBJECTHANDLE handle, uint32_t uType,
     }
 
     _ASSERTE(!"Shouldn't be trying to call HndCompareExchangeHandleExtraInfo on handle types without extra info");
-    return NULL;
+    return (uintptr_t)NULL;
 }
 #endif // !DACCESS_COMPILE
 
index 967aca5..b071f33 100644 (file)
@@ -1360,7 +1360,7 @@ void xxxTableScanQueuedBlocksAsync(PTR_HandleTable pTable, PTR_TableSegment pSeg
 
 #ifndef DACCESS_COMPILE
     // loop through, unlock all the blocks we had locked, and reset the queue nodes
-    ProcessScanQueue(pAsyncInfo, UnlockAndForgetQueuedBlocks, NULL, FALSE);
+    ProcessScanQueue(pAsyncInfo, UnlockAndForgetQueuedBlocks, (uintptr_t)NULL, FALSE);
 #endif
 
     // we are done processing this segment
@@ -1836,7 +1836,7 @@ void CALLBACK xxxTableScanHandlesAsync(PTR_HandleTable pTable,
         asyncInfo.pScanQueue = initialNode.pNext;
 
         // loop through and free all the queue nodes
-        ProcessScanQueue(&asyncInfo, FreeScanQNode, NULL, TRUE);
+        ProcessScanQueue(&asyncInfo, FreeScanQNode, (uintptr_t)NULL, TRUE);
     }
 
     // unlink our async scanning info from the table
index 992678b..9dc0947 100644 (file)
@@ -11,6 +11,10 @@ Module Name:
 Abstract:
     Read memory and cpu limits for the current process
 --*/
+#ifdef __FreeBSD__
+#define _WITH_GETLINE
+#endif
+
 #include <cstdint>
 #include <cstddef>
 #include <cassert>