From be687718c69fed52d33787a5c156b9393d03eb41 Mon Sep 17 00:00:00 2001 From: Mathis Chenuet Date: Sun, 18 Jan 2015 16:50:28 +0100 Subject: [PATCH] typo fix --- protocol.txt | 2 +- src/com/sheepit/client/Client.java | 10 +++++----- src/com/sheepit/client/Server.java | 10 +++++----- src/com/sheepit/client/os/Mac.java | 4 ++-- 4 files changed, 13 insertions(+), 13 deletions(-) diff --git a/protocol.txt b/protocol.txt index c71e77b..25313e8 100644 --- a/protocol.txt +++ b/protocol.txt @@ -85,7 +85,7 @@ where X: * 201 => The client does not have rendering right. * 202 => Client's session is dead. Client should do a config request before requesting a new job. * 203 => Client's session have been disabled (usually because the client is sending broken frame). The client warms the end user and logout. - * 205 => No renderer is available for Client's hardware (pair of OS and architecture). For example Blender is not avaible for MacOS 32bits. + * 205 => No renderer is available for Client's hardware (pair of OS and architecture). For example Blender is not available for MacOS 32bits. * something else => unknown error Answer with no error: diff --git a/src/com/sheepit/client/Client.java b/src/com/sheepit/client/Client.java index e1d51ae..556dea2 100644 --- a/src/com/sheepit/client/Client.java +++ b/src/com/sheepit/client/Client.java @@ -481,9 +481,9 @@ public class Client { return Error.Type.DOWNLOAD_FILE; } - ret = this.prepareWorkeableDirectory(ajob); // decompress renderer and scene archives + ret = this.prepareWorkingDirectory(ajob); // decompress renderer and scene archives if (ret != 0) { - this.log.error("Client::work problem with this.prepareWorkeableDirectory (ret " + ret + ")"); + this.log.error("Client::work problem with this.prepareWorkingDirectory (ret " + ret + ")"); return Error.Type.CAN_NOT_CREATE_DIRECTORY; } @@ -765,7 +765,7 @@ public class Client { return 0; } - protected int prepareWorkeableDirectory(Job ajob) { + protected int prepareWorkingDirectory(Job ajob) { int ret; String renderer_archive = ajob.getRendererArchivePath(); String renderer_path = ajob.getRendererDirectory(); @@ -781,7 +781,7 @@ public class Client { // unzip the archive ret = Utils.unzipFileIntoDirectory(renderer_archive, renderer_path); if (ret != 0) { - this.gui.error("Client::prepareWorkeableDirectory, error with Utils.unzipFileIntoDirectory of the renderer (returned " + ret + ")"); + this.gui.error("Client::prepareWorkingDirectory, error with Utils.unzipFileIntoDirectory of the renderer (returned " + ret + ")"); return -1; } } @@ -800,7 +800,7 @@ public class Client { // unzip the archive ret = Utils.unzipFileIntoDirectory(scene_archive, scene_path); if (ret != 0) { - this.gui.error("Client::prepareWorkeableDirectory, error with Utils.unzipFileIntoDirectory of the scene (returned " + ret + ")"); + this.gui.error("Client::prepareWorkingDirectory, error with Utils.unzipFileIntoDirectory of the scene (returned " + ret + ")"); return -2; } } diff --git a/src/com/sheepit/client/Server.java b/src/com/sheepit/client/Server.java index 9e78ee4..5d73154 100644 --- a/src/com/sheepit/client/Server.java +++ b/src/com/sheepit/client/Server.java @@ -524,14 +524,14 @@ public class Server extends Thread implements HostnameVerifier, X509TrustManager FileOutputStream fos = new FileOutputStream(destination_); byte[] ch = new byte[512 * 1024]; int nb; - long writed = 0; + long written = 0; long last_gui_update = 0; // size in byte while ((nb = inStrm.read(ch)) != -1) { fos.write(ch, 0, nb); - writed += nb; - if ((writed - last_gui_update) > 1000000) { // only update the gui every 1MB - gui_.status(String.format(status_, (int) (100.0 * writed / size))); - last_gui_update = writed; + written += nb; + if ((written - last_gui_update) > 1000000) { // only update the gui every 1MB + gui_.status(String.format(status_, (int) (100.0 * written / size))); + last_gui_update = written; } } fos.close(); diff --git a/src/com/sheepit/client/os/Mac.java b/src/com/sheepit/client/os/Mac.java index b59f5be..b4bc02a 100644 --- a/src/com/sheepit/client/os/Mac.java +++ b/src/com/sheepit/client/os/Mac.java @@ -151,7 +151,7 @@ public class Mac extends OS { actual_command = Utils.concatAll(low, command); } else { - Log.getInstance(null).error("No low priority binary, will not launch renderer in normal prioity"); + Log.getInstance(null).error("No low priority binary, will not launch renderer in normal priority"); } ProcessBuilder builder = new ProcessBuilder(actual_command); builder.redirectErrorStream(true); @@ -177,7 +177,7 @@ public class Mac extends OS { } catch (IOException e) { this.hasNiceBinary = false; - Log.getInstance(null).error("Failed to find low priority binary, will not launch renderer in normal prioity (" + e + ")"); + Log.getInstance(null).error("Failed to find low priority binary, will not launch renderer in normal priority (" + e + ")"); } finally { if (process != null) {