/[projet1]/public/pc/tools/osdk/main/common/sources/common.cpp
Defence Force logotype

Diff of /public/pc/tools/osdk/main/common/sources/common.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1074 by dbug, Fri Dec 20 17:42:53 2013 UTC revision 1075 by dbug, Sun Jan 12 20:13:41 2014 UTC
# Line 275  bool LoadText(const char* pcFileName,std Line 275  bool LoadText(const char* pcFileName,std
275    }    }
276  }  }
277    
278    bool IsUpToDate(const char* sourceFile,const char* targetFile)
279    {
280      struct stat sourceFileInfo;
281      struct stat targetFileInfo;
282    
283      if (stat(sourceFile,&sourceFileInfo)== -1)
284      {
285        return false;
286      }
287      if (stat(targetFile,&targetFileInfo)== -1)
288      {
289        return false;
290      }
291      return (targetFileInfo.st_mtime >= sourceFileInfo.st_mtime);
292    }
293    
294    bool IsUpToDate(const std::string& sourceFile,const std::string& targetFile)
295    {
296      return IsUpToDate(sourceFile.c_str(),targetFile.c_str());
297    }
298    
299    
300  int StringReplace(std::string& cMainString,const std::string& cSearchedString,const std::string& cReplaceString)  int StringReplace(std::string& cMainString,const std::string& cSearchedString,const std::string& cReplaceString)
301  {  {

Legend:
Removed from v.1074  
changed lines
  Added in v.1075

  ViewVC Help
Powered by ViewVC 1.1.26