version 1.32, 2010/07/23 21:46:05 |
version 1.33, 2010/07/28 21:19:30 |
|
|
static char *preadline(int, size_t, off_t); |
static char *preadline(int, size_t, off_t); |
|
|
static int Tflag; |
static int Tflag; |
static int context = 3; |
int diff_context = 3; |
int diff_format = D_NORMAL; |
int diff_format = D_NORMAL; |
const char *diff_file1 = NULL; |
const char *diff_file1 = NULL; |
const char *diff_file2 = NULL; |
const char *diff_file2 = NULL; |
|
|
diff_head(); |
diff_head(); |
|
|
anychange = 1; |
anychange = 1; |
} else if (a > context_vec_ptr->b + (2 * context) + 1 && |
} else if (a > context_vec_ptr->b + (2 * diff_context) + 1 && |
c > context_vec_ptr->d + (2 * context) + 1) { |
c > context_vec_ptr->d + (2 * diff_context) + 1) { |
/* |
/* |
* If this change is more than 'context' lines from the |
* If this change is more than 'context' lines from the |
* previous change, dump the record and reset it. |
* previous change, dump the record and reset it. |
|
|
return; |
return; |
|
|
b = d = 0; /* gcc */ |
b = d = 0; /* gcc */ |
lowa = MAX(1, cvp->a - context); |
lowa = MAX(1, cvp->a - diff_context); |
upb = MIN(len[0], context_vec_ptr->b + context); |
upb = MIN(len[0], context_vec_ptr->b + diff_context); |
lowc = MAX(1, cvp->c - context); |
lowc = MAX(1, cvp->c - diff_context); |
upd = MIN(len[1], context_vec_ptr->d + context); |
upd = MIN(len[1], context_vec_ptr->d + diff_context); |
|
|
diff_output("***************"); |
diff_output("***************"); |
if ((flags & D_PROTOTYPE)) { |
if ((flags & D_PROTOTYPE)) { |
|
|
return; |
return; |
|
|
b = d = 0; /* gcc */ |
b = d = 0; /* gcc */ |
lowa = MAX(1, cvp->a - context); |
lowa = MAX(1, cvp->a - diff_context); |
upb = MIN(len[0], context_vec_ptr->b + context); |
upb = MIN(len[0], context_vec_ptr->b + diff_context); |
lowc = MAX(1, cvp->c - context); |
lowc = MAX(1, cvp->c - diff_context); |
upd = MIN(len[1], context_vec_ptr->d + context); |
upd = MIN(len[1], context_vec_ptr->d + diff_context); |
|
|
diff_output("@@ -"); |
diff_output("@@ -"); |
uni_range(lowa, upb); |
uni_range(lowa, upb); |