]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/inspircd.cpp
Check for windows drive letters on the start of paths and treat them the same as...
[user/henk/code/inspircd.git] / src / inspircd.cpp
index 97e2c77e352d9da2fecc4f477caaf606687b4484..50e76b2a2427ee9dd3e24e2b58c1bd23580bd72d 100644 (file)
@@ -351,7 +351,8 @@ bool InspIRCd::DaemonSeed()
 void InspIRCd::WritePID(const std::string &filename)
 {
        std::string fname = (filename.empty() ? "inspircd.pid" : filename);
-       if (*(fname.begin()) != '/')
+       std::replace(fname.begin(), fname.end(), '\\', '/');
+       if ((fname[0] != '/') && (!Config->StartsWithWindowsDriveLetter(filename)))
        {
                std::string::size_type pos;
                std::string confpath = this->ConfigFileName;