From 6ccbe1d8bf40ba94520d30eedbb5eff8958ca2c2 Mon Sep 17 00:00:00 2001 From: adam-m Date: Mon, 3 Dec 2012 17:43:23 -0500 Subject: [PATCH] fix for AUT-691 Crash --- .../autopsy/corecomponents/DataResultViewerTable.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Core/src/org/sleuthkit/autopsy/corecomponents/DataResultViewerTable.java b/Core/src/org/sleuthkit/autopsy/corecomponents/DataResultViewerTable.java index 637729198f..d37fe5406e 100644 --- a/Core/src/org/sleuthkit/autopsy/corecomponents/DataResultViewerTable.java +++ b/Core/src/org/sleuthkit/autopsy/corecomponents/DataResultViewerTable.java @@ -404,7 +404,7 @@ public class DataResultViewerTable extends AbstractDataResultViewer { * @param table the object table * @return max the maximum width of the column */ - private int getMaxColumnWidth(int index, FontMetrics metrics, int margin, int padding, String header, Object[][] table) { + private synchronized int getMaxColumnWidth(int index, FontMetrics metrics, int margin, int padding, String header, Object[][] table) { // set the tree (the node / names column) width String headerName = header; int headerWidth = metrics.stringWidth(headerName); // length of the header @@ -412,7 +412,7 @@ public class DataResultViewerTable extends AbstractDataResultViewer { // Get maximum width of column data for (int i = 0; i < table.length; i++) { - if (index >= table[i].length) { + if (table[i] == null || index >= table[i].length) { continue; } String test = table[i][index].toString();