Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1diff --git a/src/MACLib/APELink.cpp b/src/MACLib/APELink.cpp 2index d349f4b..b00ec83 100644 3--- a/src/MACLib/APELink.cpp 4+++ b/src/MACLib/APELink.cpp 5@@ -63,10 +63,10 @@ void CAPELink::ParseData(const char * pData, const str_utf16 * pFilename) 6 if (pData != NULL) 7 { 8 // parse out the information 9- char * pHeader = strstr(pData, APE_LINK_HEADER); 10- char * pImageFile = strstr(pData, APE_LINK_IMAGE_FILE_TAG); 11- char * pStartBlock = strstr(pData, APE_LINK_START_BLOCK_TAG); 12- char * pFinishBlock = strstr(pData, APE_LINK_FINISH_BLOCK_TAG); 13+ const char * pHeader = strstr(pData, APE_LINK_HEADER); 14+ const char * pImageFile = strstr(pData, APE_LINK_IMAGE_FILE_TAG); 15+ const char * pStartBlock = strstr(pData, APE_LINK_START_BLOCK_TAG); 16+ const char * pFinishBlock = strstr(pData, APE_LINK_FINISH_BLOCK_TAG); 17 18 if (pHeader && pImageFile && pStartBlock && pFinishBlock) 19 { 20@@ -81,7 +81,7 @@ void CAPELink::ParseData(const char * pData, const str_utf16 * pFilename) 21 22 // get the path 23 char cImageFile[MAX_PATH + 1]; int nIndex = 0; 24- char * pImageCharacter = &pImageFile[strlen(APE_LINK_IMAGE_FILE_TAG)]; 25+ const char * pImageCharacter = &pImageFile[strlen(APE_LINK_IMAGE_FILE_TAG)]; 26 while ((*pImageCharacter != 0) && (*pImageCharacter != '\r') && (*pImageCharacter != '\n')) 27 cImageFile[nIndex++] = *pImageCharacter++; 28 cImageFile[nIndex] = 0; 29diff --git a/src/Shared/All.h b/src/Shared/All.h 30index 328addc..7730e89 100644 31--- a/src/Shared/All.h 32+++ b/src/Shared/All.h 33@@ -21,6 +21,8 @@ Global includes 34 #include <windows.h> 35 #endif 36 37+#include <stdlib.h> 38+ 39 #ifdef _WIN32 40 #include <mmsystem.h> 41 #include <tchar.h> 42@@ -34,7 +36,6 @@ Global includes 43 #include "NoWindows.h" 44 #endif 45 46-#include <stdlib.h> 47 #include <memory.h> 48 #include <stdio.h> 49 #include <math.h>