Fix warning in uncrustify
[alexxy/gromacs.git] / admin / uncrustify.sh
index da28285613f3a603577293df089b9567aee7d6b3..a4e2876dc16f738e5fd51bcfe7431855df5ec658 100755 (executable)
@@ -276,7 +276,11 @@ elif [[ $action == update-workdir ]] ; then
 fi
 
 # Report what was done
-sort $tmpdir/messages | tee $srcdir/$warning_file
+if [ "$warning_file" ]; then
+     sort $tmpdir/messages | tee $srcdir/$warning_file
+else
+     sort $tmpdir/messages
+fi
 
 rm -rf $tmpdir
 exit $changes