<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">Upstream: https://anonscm.debian.org/cgit/collab-maint/tardiff.git/tree/debian/patches/fix-statistic.diff

Description: Fix calculation of statistics (option -s)
 Using normal instead of unique diff is far easier to parse
 unambiguously.
Author: Axel Beckert &lt;abe@debian.org&gt;
Bug-Debian: https://bugs.debian.org/802098

Index: tardiff
===================================================================
--- tardiff	2015-10-17 16:37:09.675959837 +0200
+++ tardiff	2015-10-17 16:40:07.739438492 +0200
@@ -116,15 +116,15 @@
 	if(-d $file1 and -d $file2){
 		return 0;
 	}elsif(-f $file1 and -f $file2){
-		my $diff = `diff -u $file1 $file2`;
+		my $diff = `diff $file1 $file2`;
 		if($diff){
 			if($opt_stats){
 				my $plus = 0;
 				my $minus = 0;
 				foreach my $line(split(/\n/, $diff)){
-					if($line =~ /^+\ /){
+					if($line =~ /^&gt;/){
 						$plus++;
-					}elsif($line =~ /^-\ /){
+					}elsif($line =~ /^&lt;/){
 						$minus++;
 					}
 				}
</pre></body></html>