diff options
-rw-r--r-- | src/com/vaadin/ui/Upload.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/com/vaadin/ui/Upload.java b/src/com/vaadin/ui/Upload.java index 238217a4c2..70e16e1ded 100644 --- a/src/com/vaadin/ui/Upload.java +++ b/src/com/vaadin/ui/Upload.java @@ -161,7 +161,8 @@ public class Upload extends AbstractComponent implements Component.Focusable { while ((bytesRead = in.read(buffer)) > 0) { out.write(buffer, 0, bytesRead); totalBytes += bytesRead; - if (progressListener != null && contentLength > 0) { + if (contentLength > 0 + && (progressListeners != null || progressListener != null)) { // update progress if listener set and contentLength // received synchronized (application) { |