Skip to content

Commit

Permalink
fixed export bug (really)
Browse files Browse the repository at this point in the history
  • Loading branch information
ryupold committed Apr 4, 2016
1 parent b3720b6 commit 7a446da
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 2 deletions.
Binary file modified DocZ.jar
Binary file not shown.
2 changes: 2 additions & 0 deletions nbproject/private/private.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
</group>
<group>
<file>file:/C:/Users/realr/Documents/docz/src/docz/DatabaseExporter.java</file>
<file>file:/C:/Users/realr/Documents/docz/src/docz/Doc.java</file>
<file>file:/C:/Users/realr/Documents/docz/src/docz/ContentPanel.java</file>
<file>file:/C:/Users/realr/Documents/docz/src/docz/DataHandler.java</file>
<file>file:/C:/Users/realr/Documents/docz/src/docz/DocZMainFrame.java</file>
</group>
Expand Down
4 changes: 2 additions & 2 deletions src/docz/DataHandler.java
Original file line number Diff line number Diff line change
Expand Up @@ -1018,9 +1018,9 @@ public void start() throws Exception {
long fileSize = r.resultSet.getLong(5);
byte[] buffer = new byte[1024];
int tmpCount = 0;
while ((tmpCount = byteStream.read(buffer)) > 0) {
while ((tmpCount = byteStream.read(buffer, 0, buffer.length)) > 0) {
bytesRead += tmpCount;
fos.write(buffer);
fos.write(buffer, 0, tmpCount);
double percent = (double) bytesRead / (double) fileSize;
if(isCanceled()) {Log.l("exporting aborted"); return;}
processing(((double) bytesRead / (double) fileSize) * 1.0 / fileCount + i / fileCount * 0.5 + 0.5, "exporting file " + fname);
Expand Down
Binary file modified store/DocZ.jar
Binary file not shown.

0 comments on commit 7a446da

Please sign in to comment.