Index: /applications/editors/josm/plugins/o5m/src/org/openstreetmap/josm/plugins/o5m/io/O5mReader.java
===================================================================
--- /applications/editors/josm/plugins/o5m/src/org/openstreetmap/josm/plugins/o5m/io/O5mReader.java	(revision 34834)
+++ /applications/editors/josm/plugins/o5m/src/org/openstreetmap/josm/plugins/o5m/io/O5mReader.java	(revision 34835)
@@ -8,4 +8,5 @@
 import java.io.IOException;
 import java.io.InputStream;
+import java.nio.charset.StandardCharsets;
 import java.util.ArrayList;
 import java.util.Collection;
@@ -39,5 +40,5 @@
  */
 public class O5mReader extends AbstractReader {
-    public IllegalDataException exception = null;
+    private IllegalDataException exception = null;
     private boolean discourageUpload;
     
@@ -80,5 +81,4 @@
     private BufferedInputStream fis;
     private InputStream is;
-    private ByteArrayInputStream bis;
 
     // buffer for byte -> String conversions
@@ -94,5 +94,5 @@
     private int bytesToRead;
     // total number of bytes read from stream
-    long countBytes;
+    private long countBytes;
 
     // for delta calculations
@@ -103,5 +103,6 @@
     private long lastTs;
     private long lastChangeSet;
-    private int lastLon, lastLat;
+    private int lastLon;
+    private int lastLat;
     private int version;
     private User osmUser;
@@ -175,8 +176,7 @@
                     } 
                     ioPos = 0;
-                    bis = new ByteArrayInputStream(ioBuf, 0, bytesToRead);
-                    is = bis;
+                    is = new ByteArrayInputStream(ioBuf, 0, bytesToRead);
                     break;                    
-                default:    
+                default: break;    
                 }
             }
@@ -229,5 +229,5 @@
             ds.addDataSource(new DataSource(b, header));
         } else {
-            Logging.error("Invalid Bounds: "+b);
+            Logging.error("Invalid Bounds: " + b);
         }
     }
@@ -235,7 +235,6 @@
     /**
      * read a node data set 
-     * @throws IOException in case of I/O error
-     */
-    private void readNode() throws IOException {
+     */
+    private void readNode() {
         if (exception != null)
             return;
@@ -285,7 +284,6 @@
     /**
      * read a way data set
-     * @throws IOException in case of I/O error
-     */
-    private void readWay() throws IOException {
+     */
+    private void readWay() {
         if (exception != null)
             return;
@@ -333,7 +331,6 @@
     /**
      * read a relation data set
-     * @throws IOException in case of I/O error
-     */
-    private void readRel() throws IOException {
+     */
+    private void readRel() {
         if (exception != null)
             return;
@@ -387,5 +384,5 @@
     }
 
-    private Map<String, String> readTags() throws IOException {
+    private Map<String, String> readTags() {
         Map<String, String> keys = new HashMap<>();
         while (bytesToRead > 0) {
@@ -424,7 +421,6 @@
      * Read version, time stamp and change set and author.  
      * We are not interested in the values, but we have to maintain the string table.
-     * @throws IOException in case of I/O error
-     */
-    private void readVersionTsAuthor() throws IOException {
+     */
+    private void readVersionTsAuthor() {
         stringPair[0] = null;
         stringPair[1] = null;
@@ -442,7 +438,6 @@
     /**
      * Read author . 
-     * @throws IOException in case of I/O error
-     */
-    private void readAuthor() throws IOException {
+     */
+    private void readAuthor() {
         int stringRef = readUnsignedNum32();
         if (stringRef == 0) {
@@ -465,5 +460,5 @@
 
                 if (b == 0)
-                    stringPair[1] = new String(cnvBuffer, start, buffPos-1, "UTF-8");
+                    stringPair[1] = new String(cnvBuffer, start, buffPos-1, StandardCharsets.UTF_8);
             }
             long bytes = toReadStart - bytesToRead;
@@ -472,5 +467,5 @@
         } else 
             setStringRefPair(stringRef);
-        if (stringPair[0] != null && stringPair[0].isEmpty() == false) {
+        if (stringPair[0] != null && !stringPair[0].isEmpty()) {
             long uid = Long.parseLong(stringPair[0]);
             osmUser = User.createOsmUser(uid, stringPair[1]);
@@ -482,7 +477,6 @@
      * read object type ("0".."2") concatenated with role (single string) 
      * @return 0..3 for type (3 means unknown)
-     * @throws IOException in case of I/O error
-     */
-    private int readRelRef() throws IOException {
+     */
+    private int readRelRef() {
         int refType = -1;
         long toReadStart = bytesToRead;
@@ -505,5 +499,5 @@
 
                 if (b == 0)
-                    stringPair[1] = new String(cnvBuffer, start, buffPos-1, "UTF-8");
+                    stringPair[1] = new String(cnvBuffer, start, buffPos-1, StandardCharsets.UTF_8);
             }
             long bytes = toReadStart - bytesToRead;
@@ -525,7 +519,6 @@
     /**
      * read a string pair (see o5m definition)
-     * @throws IOException in case of I/O error
-     */
-    private void readStringPair() throws IOException {
+     */
+    private void readStringPair() {
         int stringRef = readUnsignedNum32();
         if (stringRef == 0) {
@@ -540,5 +533,5 @@
 
                 if (b == 0) {
-                    stringPair[cnt] = new String(cnvBuffer, start, buffPos-start-1, "UTF-8");
+                    stringPair[cnt] = new String(cnvBuffer, start, buffPos-start-1, StandardCharsets.UTF_8);
                     ++cnt;
                     start = buffPos;
@@ -570,5 +563,5 @@
             throw new IOException(tr("unsupported header"));
         }
-        header = new String(ioBuf, 0, 3, "UTF-8");
+        header = new String(ioBuf, 0, 3, StandardCharsets.UTF_8);
     }
 
@@ -707,4 +700,5 @@
      * Exception thrown after user cancellation.
      */
+    @SuppressWarnings("serial")
     private static final class O5mParsingCancelException extends Exception implements ImportCancelException {
         O5mParsingCancelException(String msg) {
