Accept stdin as input for patcheck.
authorRafaël Carré <rafael.carre@gmail.com>
Sun, 25 Jul 2010 15:02:27 +0000 (15:02 +0000)
committerCarl Eugen Hoyos <cehoyos@rainbow.studorg.tuwien.ac.at>
Sun, 25 Jul 2010 15:02:27 +0000 (15:02 +0000)
Patch by Rafaël Carré, rafael d carre a gmail

Originally committed as revision 24499 to svn://svn.ffmpeg.org/ffmpeg/trunk

tools/patcheck

index 521138a..de20500 100755 (executable)
@@ -1,5 +1,13 @@
 #!/bin/sh
 
+# if no argument provided, write stdin to a file and re-run the script
+if [ $# = 0 ]; then
+    cat > patcheck.stdout
+    $0 patcheck.stdout
+    rm -f patcheck.stdout
+    exit
+fi
+
 TMP=patcheck.tmp
 OPT="-nH"
 #FILES=`grep '^+++' $* | sed 's/+++ //g'`