Merge pull request #92 from motlin/master

Fixes from static-analysis tools
This commit is contained in:
Trustin Lee 2011-11-30 22:50:20 -08:00
commit 040b74f764
5 changed files with 4 additions and 6 deletions

View File

@ -46,7 +46,7 @@ public class WebSocketServerIndexPage {
"} else {" + NEWLINE + "} else {" + NEWLINE +
" alert(\"Your browser does not support Web Socket.\");" + NEWLINE + " alert(\"Your browser does not support Web Socket.\");" + NEWLINE +
"}" + NEWLINE + "}" + NEWLINE +
"" + NEWLINE + NEWLINE +
"function send(message) {" + NEWLINE + "function send(message) {" + NEWLINE +
" if (!window.WebSocket) { return; }" + NEWLINE + " if (!window.WebSocket) { return; }" + NEWLINE +
" if (socket.readyState == WebSocket.OPEN) {" + NEWLINE + " if (socket.readyState == WebSocket.OPEN) {" + NEWLINE +

View File

@ -50,7 +50,7 @@ public class WebSocketServerIndexPage {
"} else {" + NEWLINE + "} else {" + NEWLINE +
" alert(\"Your browser does not support Web Socket.\");" + NEWLINE + " alert(\"Your browser does not support Web Socket.\");" + NEWLINE +
"}" + NEWLINE + "}" + NEWLINE +
"" + NEWLINE + NEWLINE +
"function send(message) {" + NEWLINE + "function send(message) {" + NEWLINE +
" if (!window.WebSocket) { return; }" + NEWLINE + " if (!window.WebSocket) { return; }" + NEWLINE +
" if (socket.readyState == WebSocket.OPEN) {" + NEWLINE + " if (socket.readyState == WebSocket.OPEN) {" + NEWLINE +

View File

@ -50,7 +50,7 @@ public class WebSocketSslServerIndexPage {
"} else {" + NEWLINE + "} else {" + NEWLINE +
" alert(\"Your browser does not support Web Socket.\");" + NEWLINE + " alert(\"Your browser does not support Web Socket.\");" + NEWLINE +
"}" + NEWLINE + "}" + NEWLINE +
"" + NEWLINE + NEWLINE +
"function send(message) {" + NEWLINE + "function send(message) {" + NEWLINE +
" if (!window.WebSocket) { return; }" + NEWLINE + " if (!window.WebSocket) { return; }" + NEWLINE +
" if (socket.readyState == WebSocket.OPEN) {" + NEWLINE + " if (socket.readyState == WebSocket.OPEN) {" + NEWLINE +

View File

@ -92,8 +92,6 @@ public class WebSocketSslServerSslContext {
throw new Error("Failed to initialize the server-side SSLContext", e); throw new Error("Failed to initialize the server-side SSLContext", e);
} }
_serverContext = serverContext; _serverContext = serverContext;
return;
} catch (Exception ex) { } catch (Exception ex) {
logger.error("Error initializing SslContextManager. " + ex.getMessage(), ex); logger.error("Error initializing SslContextManager. " + ex.getMessage(), ex);
System.exit(1); System.exit(1);

View File

@ -93,6 +93,6 @@ public class LocalTimeServerHandler extends SimpleChannelUpstreamHandler {
} }
private static String toString(Continent c) { private static String toString(Continent c) {
return "" + c.name().charAt(0) + c.name().toLowerCase().substring(1); return c.name().charAt(0) + c.name().toLowerCase().substring(1);
} }
} }