[maven-release-plugin] copy for tag org.apache.felix.shell.remote-1.1.2
git-svn-id: https://svn.apache.org/repos/asf/felix/releases/org.apache.felix.shell.remote-1.1.2@1002212 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/doc/changelog.txt b/doc/changelog.txt
index b04ce5f..3a01a64 100644
--- a/doc/changelog.txt
+++ b/doc/changelog.txt
@@ -1,3 +1,10 @@
+Changes from 1.1.0 to 1.1.2
+---------------------------
+
+** Bug
+ * [FELIX-2604] - Remote Shell note correctly catching exceptions in
+ TerminalPrintStream.
+
Changes from 1.0.4 to 1.1.0
---------------------------
diff --git a/pom.xml b/pom.xml
index 63a6d15..ba6d46d 100644
--- a/pom.xml
+++ b/pom.xml
@@ -29,7 +29,7 @@
<description>
Provide remote access to Felix Shell or Gogo.
</description>
- <version>1.1.1-SNAPSHOT</version>
+ <version>1.1.2</version>
<artifactId>org.apache.felix.shell.remote</artifactId>
<dependencies>
<dependency>
@@ -50,7 +50,7 @@
<dependency>
<groupId>${pom.groupId}</groupId>
<artifactId>org.apache.felix.gogo.runtime</artifactId>
- <version>0.6.0</version>
+ <version>0.6.1</version>
</dependency>
</dependencies>
<build>
@@ -71,7 +71,7 @@
org.apache.felix.shell.remote.*
</Private-Package>
<DynamicImport-Package>
- org.apache.felix.service.command,org.apache.felix.shell,org.osgi.service.log
+ org.apache.felix.service.command; status="provisional",org.apache.felix.shell,org.osgi.service.log
</DynamicImport-Package>
<Include-Resource>META-INF/LICENSE=LICENSE,META-INF/NOTICE=NOTICE,META-INF/DEPENDENCIES=DEPENDENCIES</Include-Resource>
</instructions>
@@ -79,4 +79,10 @@
</plugin>
</plugins>
</build>
+
+ <scm>
+ <connection>scm:svn:https://svn.apache.org/repos/asf/felix/releases/org.apache.felix.shell.remote-1.1.2</connection>
+ <developerConnection>scm:svn:https://svn.apache.org/repos/asf/felix/releases/org.apache.felix.shell.remote-1.1.2</developerConnection>
+ <url>scm:svn:https://svn.apache.org/repos/asf/felix/releases/org.apache.felix.shell.remote-1.1.2</url>
+ </scm>
</project>
diff --git a/src/main/java/org/apache/felix/shell/remote/Shell.java b/src/main/java/org/apache/felix/shell/remote/Shell.java
index 43e230c..f706396 100644
--- a/src/main/java/org/apache/felix/shell/remote/Shell.java
+++ b/src/main/java/org/apache/felix/shell/remote/Shell.java
@@ -19,10 +19,10 @@
import java.io.BufferedReader;
import java.io.IOException;
import java.net.Socket;
-import org.apache.felix.service.command.CommandProcessor;
-import org.apache.felix.service.command.CommandSession;
import org.apache.felix.shell.ShellService;
+import org.apache.felix.service.command.CommandProcessor;
+import org.apache.felix.service.command.CommandSession;
/**
* Implements the shell.
diff --git a/src/main/java/org/apache/felix/shell/remote/TerminalPrintStream.java b/src/main/java/org/apache/felix/shell/remote/TerminalPrintStream.java
index 430e6d9..3cf2099 100644
--- a/src/main/java/org/apache/felix/shell/remote/TerminalPrintStream.java
+++ b/src/main/java/org/apache/felix/shell/remote/TerminalPrintStream.java
@@ -16,10 +16,8 @@
*/
package org.apache.felix.shell.remote;
-import java.io.IOException;
import java.io.OutputStream;
import java.io.PrintStream;
-import java.net.SocketException;
/**
* Class implementing a <tt>TerminalPrintStream</tt>.
@@ -38,45 +36,54 @@
{
super(tout);
m_services = services;
- }//constructor
+ }
public void print(String str)
{
- try
+ if (out != null)
{
- byte[] bytes = str.getBytes();
- out.write(bytes, 0, bytes.length);
- flush();
- }
- catch (Exception ex)
- {
- if (!m_isClosed)
+ try
{
- m_services.error("TerminalPrintStream::print()", ex);
+ byte[] bytes = str.getBytes();
+ out.write(bytes, 0, bytes.length);
+ flush();
+ }
+ catch (Exception ex)
+ {
+ if (!m_isClosed)
+ {
+ m_services.error("TerminalPrintStream::print()", ex);
+ }
}
}
- }//print
+ }
public void println(String str)
{
print(str + "\r\n");
- }//println
+ }
public void flush()
{
- try
+ if (out != null)
{
- out.flush();
+ try
+ {
+ out.flush();
+ }
+ catch (Exception ex)
+ {
+ if (!m_isClosed)
+ {
+ m_services.error("TerminalPrintStream::println()", ex);
+ }
+ }
}
- catch (IOException ex)
- {
- m_services.error("TerminalPrintStream::println()", ex);
- }
- }//flush
+ }
public void close()
{
m_isClosed = true;
super.close();
}
-}//class TerminalPrintStream
+}
\ No newline at end of file
diff --git a/src/main/java/org/apache/felix/shell/remote/TerminalReader.java b/src/main/java/org/apache/felix/shell/remote/TerminalReader.java
index 2ba8dd8..d75406e 100644
--- a/src/main/java/org/apache/felix/shell/remote/TerminalReader.java
+++ b/src/main/java/org/apache/felix/shell/remote/TerminalReader.java
@@ -29,8 +29,8 @@
*/
class TerminalReader extends Reader
{
- protected InputStream m_in;
- protected PrintStream m_out;
+ protected final InputStream m_in;
+ protected final PrintStream m_out;
protected boolean m_echo = false;
protected boolean m_eof = false;
@@ -169,6 +169,7 @@
{
m_in.close();
}//close
+
/**
* <b>Bell</b><br>
* The ANSI defined byte code for the NVT bell.