Pretend that the gdbmacros.cpp is actually 5 minutes older then it is.

Fixes a bug that after package installation the debugging helpers are
sometimes marked as invalid.

Reviewed-By: hjk
This commit is contained in:
dt
2009-11-12 17:34:41 +01:00
parent ffca9bb5cc
commit 9f2940297f

View File

@@ -103,6 +103,10 @@ QString DebuggingHelperLibrary::debuggingHelperLibraryByInstallData(const QStrin
{
const QString dumperSourcePath = Core::ICore::instance()->resourcePath() + QLatin1String("/gdbmacros/");
QDateTime lastModified = QFileInfo(dumperSourcePath + "gdbmacros.cpp").lastModified();
// We pretend that the lastmodified of gdbmacros.cpp is 5 minutes before what the file system says
// Because afer a installation from the package the modified dates of gdbmacros.cpp
// and the actual library are close to each other, but not deterministic in one direction
lastModified = lastModified.addSecs(-300);
foreach(const QString &directory, debuggingHelperLibraryDirectories(qtInstallData)) {
const QFileInfo fi(helperFilePath(directory));