Merge pull request #3468 from millmanorama/941-disable-view-in-timeline-for-attachments

941- disable ViewFileInTimelineAction if the file has no valid timestamps
This commit is contained in:
Richard Cordovano 2018-03-05 18:39:19 -05:00 committed by GitHub
commit 389711f2df
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -40,8 +40,12 @@ public final class ViewFileInTimelineAction extends AbstractAction {
super(displayName); super(displayName);
this.file = file; this.file = file;
if(file.getType().equals(TskData.TSK_DB_FILES_TYPE_ENUM.SLACK) if (file.getType().equals(TskData.TSK_DB_FILES_TYPE_ENUM.SLACK)
|| file.getType().equals(TskData.TSK_DB_FILES_TYPE_ENUM.UNALLOC_BLOCKS)){ || file.getType().equals(TskData.TSK_DB_FILES_TYPE_ENUM.UNALLOC_BLOCKS)
|| (file.getCrtime() <= 0
&& file.getCtime() <= 0
&& file.getMtime() <= 0
&& file.getAtime() <= 0)) {
this.setEnabled(false); this.setEnabled(false);
} }
} }