summaryrefslogtreecommitdiffstats
path: root/idrop-lite
diff options
context:
space:
mode:
authorLISA STILLWELL <lisa@dhcp152-54-6-218.wireless.europa.renci.org>2012-02-01 20:06:25 (GMT)
committer LISA STILLWELL <lisa@dhcp152-54-6-218.wireless.europa.renci.org>2012-02-01 20:06:25 (GMT)
commita4e4a8e405b5d2e9b89b4342ab2e6cfda7ae0def (patch)
tree122a914eced49c8f18b685da6cf3f7fa9dd31cdd /idrop-lite
parent7b7c0560aa7a8d553fd57a708f446312097fd21f (diff)
downloadQCG-Data-a4e4a8e405b5d2e9b89b4342ab2e6cfda7ae0def.zip
QCG-Data-a4e4a8e405b5d2e9b89b4342ab2e6cfda7ae0def.tar.gz
QCG-Data-a4e4a8e405b5d2e9b89b4342ab2e6cfda7ae0def.tar.bz2
[#620] add a check for negative file size in Upload from URL dialog
Diffstat (limited to 'idrop-lite')
-rw-r--r--idrop-lite/src/main/java/org/irods/jargon/idrop/lite/UploadFromURLDialog.java14
1 files changed, 5 insertions, 9 deletions
diff --git a/idrop-lite/src/main/java/org/irods/jargon/idrop/lite/UploadFromURLDialog.java b/idrop-lite/src/main/java/org/irods/jargon/idrop/lite/UploadFromURLDialog.java
index 905707b..80bce0c 100644
--- a/idrop-lite/src/main/java/org/irods/jargon/idrop/lite/UploadFromURLDialog.java
+++ b/idrop-lite/src/main/java/org/irods/jargon/idrop/lite/UploadFromURLDialog.java
@@ -11,27 +11,19 @@
package org.irods.jargon.idrop.lite;
-import java.awt.Color;
-import java.awt.Frame;
-import java.io.File;
import java.io.IOException;
import java.net.HttpURLConnection;
import java.net.MalformedURLException;
import java.net.URL;
-import java.net.URLConnection;
import javax.swing.BorderFactory;
-import javax.swing.DefaultCellEditor;
-import javax.swing.DropMode;
import javax.swing.ImageIcon;
-import javax.swing.JTextField;
import javax.swing.ListSelectionModel;
import javax.swing.border.BevelBorder;
import javax.swing.border.Border;
import javax.swing.event.TableModelEvent;
import javax.swing.event.TableModelListener;
import javax.swing.table.DefaultTableModel;
-import javax.swing.tree.TreePath;
import org.slf4j.LoggerFactory;
@@ -290,8 +282,12 @@ public class UploadFromURLDialog extends javax.swing.JDialog implements TableMod
idropApplet.showMessageFromOperation("Please enter a valid URL file for download");
return;
}
+ if(fileSize < 0) {
+ idropApplet.showMessageFromOperation("Please enter a valid URL file for download - file size for " +
+ urlName + " is less than 0");
+ return;
+ }
- //DefaultTableModel tblModel = idropApplet.getiDropCore().getUploadTableModel();
Object [] rowData = new Object[5];
rowData[0] = urlName;
rowData[1] = 0;