mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-03 15:15:25 +02:00
[323299] [files] remote file view adapter needs to use the latest version of IRemoteFile
This commit is contained in:
parent
9d19f6ecb4
commit
c71f34df0a
1 changed files with 4 additions and 0 deletions
|
@ -651,10 +651,14 @@ public class SystemViewRemoteFileAdapter
|
|||
IRemoteFileSubSystem ss = file.getParentRemoteFileSubSystem();
|
||||
|
||||
// make sure we have the lastest cached version otherwise could be working with a bad file that never got marked as stale
|
||||
IRemoteFile originalFile = file;
|
||||
if (ss instanceof RemoteFileSubSystem){
|
||||
IRemoteFile cachedFile = ((RemoteFileSubSystem)ss).getCachedRemoteFile(file.getAbsolutePath());
|
||||
if (cachedFile != null){
|
||||
file = cachedFile;
|
||||
if (originalFile.isStale()){ // the original file was marked stale, so the cached one should be too
|
||||
file.markStale(true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue