File tree Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -1923,8 +1923,8 @@ void DocumentWidget::CheckForChangesToFileEx() {
1923
1923
*/
1924
1924
fileMissing_ = true ;
1925
1925
lastModTime_ = 1 ;
1926
- dev_ = 0 ;
1927
- ino_ = 0 ;
1926
+ dev_ = 0 ;
1927
+ ino_ = 0 ;
1928
1928
1929
1929
/* Warn the user, if they like to be warned (Maybe this should be its
1930
1930
own preference setting: GetPrefWarnFileDeleted()) */
@@ -2801,9 +2801,13 @@ int DocumentWidget::fileWasModifiedExternally() const {
2801
2801
}
2802
2802
2803
2803
QString fullname = FullPath ();
2804
- QFileInfo fi (fullname);
2805
2804
2806
- if (lastModTime_ == fi.lastModified ().toTime_t ()) {
2805
+ struct stat statbuf;
2806
+ if (::stat (fullname.toLocal8Bit ().data (), &statbuf) != 0 ) {
2807
+ return false ;
2808
+ }
2809
+
2810
+ if (lastModTime_ == statbuf.st_mtime ) {
2807
2811
return false ;
2808
2812
}
2809
2813
You can’t perform that action at this time.
0 commit comments