Skip to content

Commit

Permalink
an extra null check; because defensive coding (#5848)
Browse files Browse the repository at this point in the history
  • Loading branch information
landreev committed Jun 13, 2019
1 parent 74afc7f commit 6b4944e
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -883,7 +883,10 @@ public long findStorageSize(Dataset dataset, boolean countCachedExtras) throws I
if (!countCachedExtras) {
if (datafile.isTabularData()) {
// count the size of the stored original, in addition to the main tab-delimited file:
total += datafile.getDataTable().getOriginalFileSize();
Long originalFileSize = datafile.getDataTable().getOriginalFileSize();
if (originalFileSize != null) {
total += originalFileSize;
}
}
} else {
StorageIO<DataFile> storageIO = datafile.getStorageIO();
Expand Down

0 comments on commit 6b4944e

Please sign in to comment.