[SCM] kodi-pvr-vdr-vnsi/master: VNSIDemux: merge two nested "if" conditions

tiber-guest at users.alioth.debian.org tiber-guest at users.alioth.debian.org
Fri Nov 4 00:20:25 UTC 2016


The following commit has been merged in the master branch:
commit 36d6aa1e1803d23fb8d7166625937fc047d32b3b
Author: Max Kellermann <max at duempel.org>
Date:   Mon Jul 4 14:54:08 2016 +0200

    VNSIDemux: merge two nested "if" conditions

diff --git a/src/VNSIDemux.cpp b/src/VNSIDemux.cpp
index bd05c30..2e3bfca 100644
--- a/src/VNSIDemux.cpp
+++ b/src/VNSIDemux.cpp
@@ -40,22 +40,20 @@ cVNSIDemux::~cVNSIDemux()
 
 void cVNSIDemux::Close()
 {
-  if (GetProtocol() >= 9)
+  if (IsOpen() && GetProtocol() >= 9)
   {
-    if (IsOpen())
-    {
-      XBMC->Log(LOG_DEBUG, "closing demuxer");
+    XBMC->Log(LOG_DEBUG, "closing demuxer");
 
-      cRequestPacket vrp;
-      vrp.init(VNSI_CHANNELSTREAM_CLOSE);
+    cRequestPacket vrp;
+    vrp.init(VNSI_CHANNELSTREAM_CLOSE);
 
-      auto resp = ReadResult(&vrp);
-      if (!resp)
-      {
-        XBMC->Log(LOG_ERROR, "%s - failed to close streaming", __FUNCTION__);
-      }
+    auto resp = ReadResult(&vrp);
+    if (!resp)
+    {
+      XBMC->Log(LOG_ERROR, "%s - failed to close streaming", __FUNCTION__);
     }
   }
+
   cVNSISession::Close();
 }
 

-- 
kodi-pvr-vdr-vnsi packaging



More information about the pkg-multimedia-commits mailing list