From 61e141388a8089d7ec0e3cf643d5ef7e99047057 Mon Sep 17 00:00:00 2001 From: Laurent Garnier Date: Fri, 22 May 2020 12:04:16 +0200 Subject: [PATCH] [enocean] Removed dependency on 'org.apache.commons.io.IOUtils' Relative to #7722 Signed-off-by: Laurent Garnier --- .../internal/transceiver/EnOceanTransceiver.java | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/bundles/org.openhab.binding.enocean/src/main/java/org/openhab/binding/enocean/internal/transceiver/EnOceanTransceiver.java b/bundles/org.openhab.binding.enocean/src/main/java/org/openhab/binding/enocean/internal/transceiver/EnOceanTransceiver.java index b3fde1a517b3f..a5cb63893542c 100644 --- a/bundles/org.openhab.binding.enocean/src/main/java/org/openhab/binding/enocean/internal/transceiver/EnOceanTransceiver.java +++ b/bundles/org.openhab.binding.enocean/src/main/java/org/openhab/binding/enocean/internal/transceiver/EnOceanTransceiver.java @@ -25,7 +25,6 @@ import java.util.concurrent.ScheduledExecutorService; import java.util.concurrent.TimeUnit; -import org.apache.commons.io.IOUtils; import org.eclipse.smarthome.core.util.HexUtils; import org.eclipse.smarthome.io.transport.serial.PortInUseException; import org.eclipse.smarthome.io.transport.serial.SerialPort; @@ -219,11 +218,17 @@ public void ShutDown() { if (outputStream != null) { logger.debug("Closing serial output stream"); - IOUtils.closeQuietly(outputStream); + try { + outputStream.close(); + } catch (IOException e) { + } } if (inputStream != null) { logger.debug("Closeing serial input stream"); - IOUtils.closeQuietly(inputStream); + try { + inputStream.close(); + } catch (IOException e) { + } } if (serialPort != null) {