byte[] bytes = os.toByteArray(); try { locallyChangedProperties.put(name, new String(bytes, "UTF-8")); } catch (UnsupportedEncodingException e) { locallyChangedProperties.put(name, new String(bytes));
} catch (IOException e) { SVNErrorManager.error(0, e); } finally { if (tmpFile2 != null) { tmpFile2.delete();
    public Map compareTo(SVNProperties properties) throws SVNException {        final Map locallyChangedProperties = new HashMap();        compareTo(properties, new ISVNPropertyComparator() {            public void propertyAdded(String name, InputStream value, int length) {                propertyChanged(name, value, length);            }            public void propertyChanged(String name, InputStream newValue, int length) {                ByteArrayOutputStream os = new ByteArrayOutputStream(length);                for(int i = 0; i < length; i++) {                    try {                        os.write(newValue.read());                    } catch (IOException e) {                    }                }                byte[] bytes = os.toByteArray();                try {                    locallyChangedProperties.put(name, new String(bytes, "UTF-8"));                } catch (UnsupportedEncodingException e) {                    locallyChangedProperties.put(name, new String(bytes));                }            }            public void propertyDeleted(String name) {                locallyChangedProperties.put(name, null);            }        });        return locallyChangedProperties;            }