Skip to content

Commit 974e004

Browse files
tklausergitster
authored andcommitted
diffcore-delta: remove unused parameter to diffcore_count_changes()
The delta_limit parameter to diffcore_count_changes() has been unused since commit ba23bbc ("diffcore-delta: make change counter to byte oriented again.", 2006-03-04). Remove the parameter and adjust all callers. Signed-off-by: Tobias Klauser <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 0b65a8d commit 974e004

File tree

5 files changed

+1
-8
lines changed

5 files changed

+1
-8
lines changed

diff.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1953,7 +1953,7 @@ static void show_dirstat(struct diff_options *options)
19531953
if (DIFF_FILE_VALID(p->one) && DIFF_FILE_VALID(p->two)) {
19541954
diff_populate_filespec(p->one, 0);
19551955
diff_populate_filespec(p->two, 0);
1956-
diffcore_count_changes(p->one, p->two, NULL, NULL, 0,
1956+
diffcore_count_changes(p->one, p->two, NULL, NULL,
19571957
&copied, &added);
19581958
diff_free_filespec_data(p->one);
19591959
diff_free_filespec_data(p->two);

diffcore-break.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,6 @@ static int should_break(struct diff_filespec *src,
7373

7474
if (diffcore_count_changes(src, dst,
7575
&src->cnt_data, &dst->cnt_data,
76-
0,
7776
&src_copied, &literal_added))
7877
return 0;
7978

diffcore-delta.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,6 @@ int diffcore_count_changes(struct diff_filespec *src,
169169
struct diff_filespec *dst,
170170
void **src_count_p,
171171
void **dst_count_p,
172-
unsigned long delta_limit,
173172
unsigned long *src_copied,
174173
unsigned long *literal_added)
175174
{

diffcore-rename.c

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,6 @@ static int estimate_similarity(struct diff_filespec *src,
144144
* call into this function in that case.
145145
*/
146146
unsigned long max_size, delta_size, base_size, src_copied, literal_added;
147-
unsigned long delta_limit;
148147
int score;
149148

150149
/* We deal only with regular files. Symlink renames are handled
@@ -190,11 +189,8 @@ static int estimate_similarity(struct diff_filespec *src,
190189
if (!dst->cnt_data && diff_populate_filespec(dst, 0))
191190
return 0;
192191

193-
delta_limit = (unsigned long)
194-
(base_size * (MAX_SCORE-minimum_score) / MAX_SCORE);
195192
if (diffcore_count_changes(src, dst,
196193
&src->cnt_data, &dst->cnt_data,
197-
delta_limit,
198194
&src_copied, &literal_added))
199195
return 0;
200196

diffcore.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,6 @@ extern int diffcore_count_changes(struct diff_filespec *src,
142142
struct diff_filespec *dst,
143143
void **src_count_p,
144144
void **dst_count_p,
145-
unsigned long delta_limit,
146145
unsigned long *src_copied,
147146
unsigned long *literal_added);
148147

0 commit comments

Comments
 (0)