[MPlayer-cvslog] r18896 - trunk/edl.c

Reimar Doeffinger Reimar.Doeffinger at stud.uni-karlsruhe.de
Tue Jul 4 14:40:06 CEST 2006


Hello,
On Tue, Jul 04, 2006 at 04:56:25AM -0400, Reynaldo H. Verdejo Pinochet wrote:
> It started just as a 'denest', then i discovered the bugs and i
> solved them, hope you can understand.

Not really. It was discussed so often that you should know all the
arguments, not to mention that it simply is CVS policy.
If only 20 people spent 10 seconds trying to figure out what this patch
is supposed to do, more time is wasted than it would have cost you to
simply do
svn diff --diff-cmd diff -x "-uwBE"
and maybe some hand-editing to get an at least somewhat clean patch.
To spare others the effort, here's the output (without any
hand-editing, which would have recognized that last "if (edl_records)" 
change as cosmetics, too).

Greetings,
Reimar Doeffinger
-------------- next part --------------
Index: edl.c
===================================================================
--- edl.c	(revision 18895)
+++ edl.c	(revision 18896)
@@ -69,8 +69,8 @@
         if ((fd = fopen(edl_filename, "r")) == NULL)
         {
             return NULL;
-        } else
-        {
+        }
+
             while (fgets(line, 99, fd) != NULL)
             {
                 lineCount++;
@@ -78,17 +79,18 @@
                     != 3)
                 {
                     mp_msg(MSGT_CPLAYER, MSGL_WARN, MSGTR_EdlBadlyFormattedLine,
-                           lineCount + 1);
+                       lineCount);
                     continue;
-                } else
-                {
+            }
+
                     if (next_edl_record && start <= next_edl_record->stop_sec)
                     {
                         mp_msg(MSGT_CPLAYER, MSGL_WARN, MSGTR_EdlNOValidLine, line);
                         mp_msg(MSGT_CPLAYER, MSGL_WARN, MSGTR_EdlBadLineOverlap,
-                               next_edl_record->prev->stop_sec, start);
+                       next_edl_record->stop_sec, start);
                         continue;    
                     }
+
                     if (stop <= start)
                     {
                         mp_msg(MSGT_CPLAYER, MSGL_WARN, MSGTR_EdlNOValidLine,
@@ -120,12 +124,14 @@
                     }
                     record_count++;
                 }
-            }
-        }
+
         fclose(fd);
     }        
-    if (edl_records) mp_msg(MSGT_CPLAYER, MSGL_INFO, MSGTR_EdlRecordsNo, record_count);
-    else mp_msg(MSGT_CPLAYER, MSGL_INFO, MSGTR_EdlQueueEmpty);
+
+    if (edl_records) 
+        mp_msg(MSGT_CPLAYER, MSGL_INFO, MSGTR_EdlRecordsNo, record_count);
+    else 
+        mp_msg(MSGT_CPLAYER, MSGL_INFO, MSGTR_EdlQueueEmpty);
 
     return edl_records;
 }


More information about the MPlayer-cvslog mailing list