- if (in == null)
- continue; // Try the next name: no such file found
-
- /* copy the library in position */
- byte[] buffer = new byte[4096];
- int bytesRead;
- while ((bytesRead = in.read(buffer)) != -1) // Read until EOF
- out.write(buffer, 0, bytesRead);
-
- out.close(); // Windows cannot open it twice, so close it first. Shame.
-
- /* load that shit */
+ if (in != null) {
+ /* copy the library in position */
+ byte[] buffer = new byte[4096];
+ int bytesRead;
+ while ((bytesRead = in.read(buffer)) != -1) // Read until EOF
+ out.write(buffer, 0, bytesRead);
+ done = true;
+ }
+ }
+ if (done) {
+ /* load that library */