patch to gst-launch - a pipeline parsing can result in an error even though a pipelin...
authorBenjamin Otte <otte@gnome.org>
Thu, 10 Apr 2003 01:40:03 +0000 (01:40 +0000)
committerBenjamin Otte <otte@gnome.org>
Thu, 10 Apr 2003 01:40:03 +0000 (01:40 +0000)
Original commit message from CVS:
patch to gst-launch - a pipeline parsing can result in an error even though a pipeline is returned

tools/gst-launch.c

index 06980d1..eba59eb 100644 (file)
@@ -259,11 +259,16 @@ main(int argc, char *argv[])
   g_free (argvn);
 
   if (!pipeline) {
-    if (error)
+    if (error) {
       fprintf(stderr, "ERROR: pipeline could not be constructed: %s\n", error->message);
-    else
+      g_error_free (error);
+    } else {
       fprintf(stderr, "ERROR: pipeline could not be constructed\n");
+    }
     exit(1);
+  } else if (error) {
+    fprintf(stderr, "WARNING: erroneous pipeline: %s\n         Trying to run anyway\n", error->message);
+    g_error_free (error);
   }
   
   if (verbose) {