[vlmc-devel] commit: VideoClipWorkflow: Avoid useless 'else if' when else can be used. ( Hugo Beauzée-Luyssen )

git at videolan.org git at videolan.org
Fri Sep 17 15:19:33 CEST 2010


vlmc | branch: master | Hugo Beauzée-Luyssen <beauze.h at gmail.com> | Fri Sep 17 15:09:53 2010 +0200| [02db2364ec57bf70c35a6da44d3d3afca91030db] | committer: Hugo Beauzée-Luyssen 

VideoClipWorkflow: Avoid useless 'else if' when else can be used.

Fix a warning on windows.

> http://git.videolan.org/gitweb.cgi/vlmc.git/?a=commit;h=02db2364ec57bf70c35a6da44d3d3afca91030db
---

 src/Workflow/VideoClipWorkflow.cpp |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/Workflow/VideoClipWorkflow.cpp b/src/Workflow/VideoClipWorkflow.cpp
index c8ec7e0..a07c1e2 100644
--- a/src/Workflow/VideoClipWorkflow.cpp
+++ b/src/Workflow/VideoClipWorkflow.cpp
@@ -128,13 +128,13 @@ VideoClipWorkflow::getOutput( ClipWorkflow::GetMode mode, qint64 currentFrame )
     //Recheck again, as the WaitCondition may have been awaken when stopping.
     if ( getNbComputedBuffers() == 0 )
         return NULL;
-    Workflow::Frame         *buff;
+    Workflow::Frame         *buff = NULL;
     if ( mode == ClipWorkflow::Pop )
     {
         buff = m_computedBuffers.dequeue();
         m_lastReturnedBuffer = buff;
     }
-    else if ( mode == ClipWorkflow::Get )
+    else
         buff = m_computedBuffers.head();
 
     quint32     *newFrame = applyFilters( buff, currentFrame,



More information about the Vlmc-devel mailing list