[vlma-devel] commit: Oops. (Adrien Grand )

git version control git at videolan.org
Thu Feb 5 02:46:39 CET 2009


vlma | branch: master | Adrien Grand <jpountz at videolan.org> | Thu Feb  5 02:46:09 2009 +0100| [5a50416e8f242ef648be2c63b1778df265b72e36] | committer: Adrien Grand 

Oops.

> http://git.videolan.org/gitweb.cgi/vlma.git/?a=commit;h=5a50416e8f242ef648be2c63b1778df265b72e36
---

 .../videolan/vlma/monitor/ServerStateMonitor.java  |    6 ++++++
 .../vlma/order/sender/TelnetConnection.java        |    1 +
 2 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/vlma-core/src/main/java/org/videolan/vlma/monitor/ServerStateMonitor.java b/vlma-core/src/main/java/org/videolan/vlma/monitor/ServerStateMonitor.java
index 09bca21..e0f0cc0 100644
--- a/vlma-core/src/main/java/org/videolan/vlma/monitor/ServerStateMonitor.java
+++ b/vlma-core/src/main/java/org/videolan/vlma/monitor/ServerStateMonitor.java
@@ -110,6 +110,12 @@ public class ServerStateMonitor extends Monitor {
             } catch (IOException e) {
                 logger.info("Unable to contact telnet interface of " + server.getName());
                 server.setUp(false);
+            } finally {
+                try {
+                    conn.close();
+                } catch (IOException e) {
+                    logger.error(e);
+                }
             }
             boolean newState = server.isUp();
             if (newState != formerState) {
diff --git a/vlma-core/src/main/java/org/videolan/vlma/order/sender/TelnetConnection.java b/vlma-core/src/main/java/org/videolan/vlma/order/sender/TelnetConnection.java
index 3bf7305..814bc42 100644
--- a/vlma-core/src/main/java/org/videolan/vlma/order/sender/TelnetConnection.java
+++ b/vlma-core/src/main/java/org/videolan/vlma/order/sender/TelnetConnection.java
@@ -125,4 +125,5 @@ public class TelnetConnection {
         }
         return response.substring(0, end);
     }
+
 }



More information about the vlma-devel mailing list