@@ -29,7 +29,12 @@ static void free_mmfile(mmfile_t *f)
29
29
free (f -> ptr );
30
30
}
31
31
32
- static void * three_way_filemerge (const char * path , mmfile_t * base , mmfile_t * our , mmfile_t * their , unsigned long * size )
32
+ static void * three_way_filemerge (struct index_state * istate ,
33
+ const char * path ,
34
+ mmfile_t * base ,
35
+ mmfile_t * our ,
36
+ mmfile_t * their ,
37
+ unsigned long * size )
33
38
{
34
39
int merge_status ;
35
40
mmbuffer_t res ;
@@ -42,15 +47,17 @@ static void *three_way_filemerge(const char *path, mmfile_t *base, mmfile_t *our
42
47
*/
43
48
merge_status = ll_merge (& res , path , base , NULL ,
44
49
our , ".our" , their , ".their" ,
45
- & the_index , NULL );
50
+ istate , NULL );
46
51
if (merge_status < 0 )
47
52
return NULL ;
48
53
49
54
* size = res .size ;
50
55
return res .ptr ;
51
56
}
52
57
53
- void * merge_blobs (const char * path , struct blob * base , struct blob * our , struct blob * their , unsigned long * size )
58
+ void * merge_blobs (struct index_state * istate , const char * path ,
59
+ struct blob * base , struct blob * our ,
60
+ struct blob * their , unsigned long * size )
54
61
{
55
62
void * res = NULL ;
56
63
mmfile_t f1 , f2 , common ;
@@ -83,7 +90,7 @@ void *merge_blobs(const char *path, struct blob *base, struct blob *our, struct
83
90
common .ptr = xstrdup ("" );
84
91
common .size = 0 ;
85
92
}
86
- res = three_way_filemerge (path , & common , & f1 , & f2 , size );
93
+ res = three_way_filemerge (istate , path , & common , & f1 , & f2 , size );
87
94
free_mmfile (& common );
88
95
out_free_f2_f1 :
89
96
free_mmfile (& f2 );
0 commit comments