From: alex Date: Tue, 27 Aug 2013 20:41:51 +0000 (+0400) Subject: Exclude CreatePidFile on Win32 platform X-Git-Tag: v0.4.4.4~8 X-Git-Url: https://git.novaco.in/?p=novacoin.git;a=commitdiff_plain;h=a69232444168079a77c9536ad9f05f07a5fa2fa0 Exclude CreatePidFile on Win32 platform --- diff --git a/src/util.cpp b/src/util.cpp index adb3fb4..e89367d 100644 --- a/src/util.cpp +++ b/src/util.cpp @@ -1108,6 +1108,7 @@ boost::filesystem::path GetPidFile() return pathPidFile; } +#ifndef WIN32 void CreatePidFile(const boost::filesystem::path &path, pid_t pid) { FILE* file = fopen(path.string().c_str(), "w"); @@ -1117,6 +1118,7 @@ void CreatePidFile(const boost::filesystem::path &path, pid_t pid) fclose(file); } } +#end bool RenameOver(boost::filesystem::path src, boost::filesystem::path dest) { diff --git a/src/util.h b/src/util.h index df1a3b1..8168216 100644 --- a/src/util.h +++ b/src/util.h @@ -215,7 +215,9 @@ boost::filesystem::path GetDefaultDataDir(); const boost::filesystem::path &GetDataDir(bool fNetSpecific = true); boost::filesystem::path GetConfigFile(); boost::filesystem::path GetPidFile(); +#ifndef WIN32 void CreatePidFile(const boost::filesystem::path &path, pid_t pid); +#endif void ReadConfigFile(std::map& mapSettingsRet, std::map >& mapMultiSettingsRet); #ifdef WIN32 boost::filesystem::path GetSpecialFolderPath(int nFolder, bool fCreate = true);