Now installer will set the url of base jar of Forge and LiteLoader.
This commit is contained in:
@@ -262,7 +262,7 @@ public class TaskWindow extends javax.swing.JDialog
|
||||
@Override
|
||||
public void onFailed(Task task) {
|
||||
SwingUtilities.invokeLater(() -> {
|
||||
failReasons.add(task.getInfo() + ": " + (null == task.getFailReason() ? "No exception" : task.getFailReason().getLocalizedMessage()));
|
||||
failReasons.add(task.getInfo() + ": " + (null == task.getFailReason() ? "No exception" : task.getFailReason().getClass().toString() + ": " + task.getFailReason().getLocalizedMessage()));
|
||||
pgsTotal.setMaximum(taskList.taskCount());
|
||||
pgsTotal.setValue(pgsTotal.getValue() + 1);
|
||||
int idx = tasks.indexOf(task);
|
||||
|
||||
@@ -431,15 +431,4 @@ public class FileUtils {
|
||||
if (f.getName().endsWith(suffix)) al.add(f);
|
||||
return al.toArray(new File[0]);
|
||||
}
|
||||
|
||||
public static byte[] toByteArray(File file) throws IOException {
|
||||
try (FileInputStream is = new FileInputStream(file)) {
|
||||
ByteArrayOutputStream os = new ByteArrayOutputStream();
|
||||
int n;
|
||||
byte[] b = new byte[1024];
|
||||
while ((n = is.read(b)) != -1) os.write(b, 0, n);
|
||||
os.close();
|
||||
return os.toByteArray();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -195,10 +195,12 @@ class BlockInputStream extends InputStream {
|
||||
filterChain = filters[i].getInputStream(filterChain);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int read() throws IOException {
|
||||
return read(tempBuf, 0, 1) == -1 ? -1 : (tempBuf[0] & 0xFF);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int read(byte[] buf, int off, int len) throws IOException {
|
||||
if (endReached)
|
||||
return -1;
|
||||
|
||||
Reference in New Issue
Block a user