Fossil

All files named ”src/diff.c”
Login

All files named ”src/diff.c”

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Ancestors of file src/diff.c from check-in fab09a1710

2013-02-08
09:37
Eliminate use of starts_with_utf16(be|le)_bom functions, starts_with_utf16_bom should be enough. External code will typically call "starts_with_utf16_bom" first, and if it returns true call "blob_to_utf8_no_bom" converting it to utf-8. There is no reason any more then for external code to know wheter the BOM was le or be. ... (file: [fc3d370f02] check-in: [fab09a1710] user: jan.nijtmans branch: trunk, size: 74196)
2013-02-07
15:28
Divide blob length check (even number of bytes) and UTF-32 check in the 3 versions of the UTF-16 BOM functions. ... (file: [3d2781b919] check-in: [be6756e26b] user: jan.nijtmans branch: trunk, size: 75180)
2013-01-15
02:29
Fix compiler warnings. ... (file: [2ada0d3531] check-in: [b3bac1158b] user: drh branch: trunk, size: 74928)
2013-01-03
20:02
Rename re_execute() to re_match(). Other fixes to regex matcher bugs that were introduced when porting the code from SQLite. ... (file: [deffd29b50] check-in: [c84051f38d] user: drh branch: trunk, size: 75023)
13:38
regexp.c (re_next_char): 3 off-by-one errors, and disallow characters > 0x10ffff unicode.c/diff.c: fix some gcc warnings ... (file: [dcfa5085b0] check-in: [a13e0a20a8] user: jan.nijtmans branch: trunk, size: 75025)
2013-01-02
11:39
s/re_exec\b/re_execute/g, for compatibility with BSD. ... (file: [97b080180d] check-in: [6a26eb3497] user: stephan branch: trunk, size: 75056)
00:58
Enhance the diff logic so that it can suppress differences that do not match a regular expression. This capability is so far only exposed on the test-diff command. ... (file: [6ad97f9bef] check-in: [97a7b924c0] user: drh branch: trunk, size: 75053)
2013-01-01
22:56
Allow the --context option on diff to have a value of 0. ... (file: [bbd9e7d590] check-in: [d74698ec28] user: drh branch: trunk, size: 72070)
2012-12-17
14:00
Enhanced comments in the diff.c source code file. No code changes. ... (file: [94c5660882] check-in: [a39a992b4e] user: drh branch: trunk, size: 71940)
2012-12-16
07:16
Remove unused local variable. ... (file: [802db6ae1d] check-in: [01d6ef7cf8] user: mistachkin branch: trunk, size: 71803)
2012-12-15
21:55
Do not attempt to translate tabs into spaces on a unified diff. ... (file: [6fdf524491] check-in: [b912619403] user: drh branch: trunk, size: 71812)
14:25
Add robustness to the handling of command-line options in the "diff" and "test-diff" commands. ... (file: [0b777826bc] check-in: [60d5b1f5a2] user: drh branch: trunk, size: 71937)
01:17
More compact representation of a left/right rewrite on side-by-side diffs. ... (file: [277116b6b8] check-in: [233c4975a8] user: drh branch: trunk, size: 71914)
00:59
If the left/right alignment in side-by-side diff becomes too busy and hard for a human to read, then show it simplified: as inserting one side and then deleting the other. ... (file: [853d818bc2] check-in: [52db049b89] user: drh branch: trunk, size: 70797)
2012-12-14
21:24
Improvements to the side-by-side diff display for indentation changes with minor edits. ... (file: [ca0160d5ae] check-in: [c4bbc4a9af] user: drh branch: trunk, size: 69939)
18:58
Rename the test-udiff command to test-diff and give it the capability to use the --tk option. ... (file: [8832774f73] check-in: [4cf8c16cd8] user: drh branch: trunk, size: 69533)
2012-12-04
01:10
The "ln" query parameter causes lines numbers to be shown on the "annotate" webpage. ... (file: [69115cf516] check-in: [08f4eda728] user: drh branch: trunk, size: 69320)
2012-11-26
22:51
Merge byte-order-mark handling enhancements to trunk. ... (file: [d793daedef] check-in: [9b800ee41c] user: mistachkin branch: trunk, size: 68868)
2012-11-15
20:43
The annotator follows name changes. ... (file: [0d960664a9] check-in: [ee33b951a4] user: drh branch: trunk, size: 67378)
2012-11-08
16:25
Short-circuit a rare pathological case in the diff generator to prevent it from taking too much time. ... (file: [a7ceea3b03] check-in: [353438a83b] user: drh branch: trunk, size: 67366)
2012-11-06
16:35
When one version of a file ends in a newline and the other does not, be sure to show that difference. Ticket [7541963870703f0]. ... (file: [eac3efd0da] check-in: [d764f449d7] user: drh branch: trunk, size: 67115)
2012-11-04
17:41
Merge the "spelling" branch into trunk, fixing a huge number of typos, mostly in comments, but occasionally in error messages or help screens. ... (file: [5006e9fe32] check-in: [db0c512767] user: drh branch: trunk, size: 67033)
2012-11-02
17:22
Adjustments to looks_like_utf16 to handle wchar_t being missing or not 2 bytes. ... (file: [cb28d616af] check-in: [7d881d8280] user: mistachkin branch: trunk, size: 67033)
08:31
speedup mimetype_from_content() by using a 256 byte array. <br>Mark VT and Ctrl-Z as text bytes, not binary. <br>Decrease maximum UTF-16 line length to 2731 <br>Check for FFFF in addition to 0, in UTF-16/binary detection. ... (file: [ca927be57f] check-in: [d804902f23] user: jan.nijtmans branch: trunk, size: 65737)
03:10
Use local variable when checking for a carriage-return in looks_like_utf8/utf16. Update custom MinGW makefile. ... (file: [ac05f9f7bb] check-in: [531b2e2df0] user: mistachkin branch: trunk, size: 65678)
02:27
Merge commit warning and file content type detection changes to trunk. ... (file: [98197f1f1a] check-in: [0c7c61447f] user: mistachkin branch: trunk, size: 65643)
2012-11-01
07:40
dont check for same BOM twice ... (file: [c6e79f2c04] check-in: [8c32e6f0dd] user: jan.nijtmans branch: trunk, size: 63239)
03:44
Merge commit warning and looks_like_text() enhancements to trunk. Further changes based on these will occur on a branch. ... (file: [c1da01cdcc] check-in: [6182584217] user: mistachkin branch: trunk, size: 63239)
2012-10-30
16:14
Style en comment fixes, backported from [d57f0a9361] ... (file: [25cec3d2bd] check-in: [c7b2b2ed3c] user: jan.nijtmans branch: trunk, size: 62966)
2012-10-29
14:45
Allow unicode files for Wiki-rendering on Windows. <p>Trying to commit a file with an UTF-16 BOM will now give a warning, just as a file containing crlf <p>The --args command line option now accept UTF-16 files as well ... (file: [5771152f24] check-in: [70b4f105eb] user: jan.nijtmans branch: trunk, size: 62461)
2012-10-28
23:01
Simplify the looks_like_binary() macro. Remove literal tab character, adjust styling and comments in looks_like_text(). ... (file: [a6943a2f41] check-in: [c8e72df08e] user: mistachkin branch: trunk, size: 62263)
21:38
- finally, do the ++j update in looks_like_text() right - More consistancy in prompt handling: accept Capitals everywhere, use '(' not '[', and abbreviate yes/no to y/N everywhere ... (file: [06680055cf] check-in: [7c527165a6] user: jan.nijtmans branch: trunk, size: 62226)
20:47
.. but don't forget to update j ... (file: [b3196ae3ca] check-in: [6542935c9d] user: jan.nijtmans branch: trunk, size: 62223)
20:40
speed-up looks_like_text(), by eliminating variable "i" and handle first character separately. ... (file: [c7a1144003] check-in: [204680eedc] user: jan.nijtmans branch: trunk, size: 62221)
09:34
modify looks_like_binary() to looks_like_text() such that it is usable in cr_warning() as well ... (file: [b517463575] check-in: [1bffce5230] user: jan.nijtmans branch: trunk, size: 62099)
2012-10-26
02:35
Improvements to side-by-side diff alignment. ... (file: [c3dbacc3e4] check-in: [511405f426] user: drh branch: trunk, size: 61883)
01:38
Improvements to the way binary files are detected. ... (file: [2fb8301afe] check-in: [8a1c80fb34] user: drh branch: trunk, size: 61221)
2012-10-05
20:39
Add the "stash show" command. Simplifications to the diff code, and especially the looks_like_binary() function. ... (file: [ba6c48d4b0] check-in: [4e0e69f691] user: drh branch: trunk, size: 61225)
2012-10-02
22:59
Merge the enhancements that adds the "diff-binary" setting for passing binary files to the external diff program. ... (file: [8be46c386b] check-in: [f8339c2743] user: drh branch: trunk, size: 60843)
2012-09-27
01:38
Fixes to the --tk diff option to support unified diff on Windows. ... (file: [2211c7d89b] check-in: [1048bccf14] user: mistachkin branch: trunk, size: 60205)
00:37
Allow unified diff for the --tk diff option. ... (file: [382886537f] check-in: [5be507df71] user: mistachkin branch: trunk, size: 59982)
2012-09-26
00:11
Escape "&lt;" and "&gt;" characters denoting removed and inserted line in the HTML version of side-by-side diff. ... (file: [1f6c64f1db] check-in: [28cfb2fb10] user: drh branch: trunk, size: 59845)
2012-08-29
19:41
Allow UTF-8 characters in sources. translate.exe will translate it to ASCII ... (file: [c98621e358] check-in: [208d67675c] user: jan.nijtmans branch: trunk, size: 59653)
2012-08-20
19:01
Expand the "diffFlags" variable to 64-bits in order to accommodate new options to the various "diff" commands. ... (file: [02c6c15cda] check-in: [2b1767500e] user: drh branch: trunk, size: 59654)
2012-06-22
22:39
Huge performance improvement for certain pathological cases for diffing of very large files. ... (file: [42067ab6c1] check-in: [9e15437e97] user: drh branch: trunk, size: 59552)
2012-06-20
11:02
Account for multibyte unicode characters when computing column widths for side-by-side diffs. ... (file: [58d1a8991b] check-in: [484f8d29af] user: drh branch: trunk, size: 59537)
10:57
Add a comment that contains multi-byte unicode characters. This will be used for testing diff logic. ... (file: [d1c60722e0] check-in: [d1fc2f4a16] user: drh branch: trunk, size: 59506)
2012-04-28
08:05
Move the enhanced spider-defense mechanism into the trunk. ... (file: [c8c7a3a979] check-in: [433cde1ce8] user: drh branch: trunk, size: 59352)
2012-04-06
17:24
(1) Show cherrypick and backout merges in the status command (2) Allow partial commits of cherrypick and backout merges (3) Prompt user to continue if a check-in comment is unedited (4) Fixing a jump on uninitialized data on web sbs diff - cherrypick of [92b2a5c390467a] (5) Updates against an uncommitted merge are now a warning, not a fatal error. ... (file: [58c6432c3b] check-in: [195517a9c9] user: drh branch: trunk, size: 59358)
2012-03-19
11:58
Avoid a valgrind warning in the side-by-side diff logic. ... (file: [9787d3423d] check-in: [9262546e43] user: drh branch: trunk, size: 59341)
2012-03-09
02:07
Tweak to the side-by-side diff alignment algorithm. Add diff test cases to the release checklist. ... (file: [f7608cab26] check-in: [3be264b57f] user: drh branch: trunk, size: 59313)
2012-02-24
13:40
Merge wideAnnotateUser and jsonWarnings into trunk. ... (file: [78c74c3b37] check-in: [18dd383e5e] user: drh branch: trunk, size: 59263)
2012-02-11
18:25
Further diff enhancements: Allow up to two diff-marks per line on a side-by-side diff. ... (file: [b1fa7e636c] check-in: [937514b968] user: drh branch: trunk, size: 59259)
2012-02-10
23:03
Merge in documentation updates. ... (file: [1d49306d9e] check-in: [75ea5ac672] user: drh branch: trunk, size: 54253)
2012-02-07
20:04
Another minor performance enhancement on sbs diff. ... (file: [f78d6f216c] check-in: [3e3feb2dda] user: drh branch: trunk, size: 54215)
18:58
Performance optimization for the alignment calculation on side-by-side diffs. Noticably faster. ... (file: [0143d68811] check-in: [87f867018b] user: drh branch: trunk, size: 54222)
18:13
Optimize the inner loop of the LCS algorithm for the main diff generator. ... (file: [1a183093d6] check-in: [4ab6071145] user: drh branch: trunk, size: 53011)
16:13
Minor tweak to the side-by-side alignment algorithm so that it handles pure white-space lines better. ... (file: [ff877a1c9d] check-in: [312590a9ee] user: drh branch: trunk, size: 52705)
15:38
Add the --brief option to the "diff" command. ... (file: [abe39d187f] check-in: [e0565d4351] user: drh branch: trunk, size: 52707)
04:15
Add chunk number fragment marks to HTML diff output. ... (file: [ac353718d9] check-in: [b1530c29ab] user: drh branch: trunk, size: 52394)
03:57
Convert the similarity measure for side-by-side diff alignment to use LCS instead of edit distance. LCS is faster and gives comparable results. ... (file: [9d3dd93b35] check-in: [469462b69a] user: drh branch: trunk, size: 52132)
00:01
Change back to using minimum edit distance for computing similarity of lines for alignment in side-by-side diff change blocks. ... (file: [fc00bfd839] check-in: [51bda5e441] user: drh branch: trunk, size: 52812)
2012-02-06
15:21
Merge the diff enhancements from the diff-experimental branch into trunk. ... (file: [d46d49428a] check-in: [bba7aea8ca] user: drh branch: trunk, size: 52116)
2012-02-05
20:22
Add the "diff optimizer" which tries to shift inserts and deletes to align with natural boundaries in the text. The resulting diff is no more or less correct than the original; it just seems more natural to human readers. ... (file: [5c86b214e2] check-in: [98cf5c33bc] user: drh branch: trunk, size: 45067)
17:19
Rearrange code and edit comments in diff logic, for clarity of presentation. No functional changes. ... (file: [75dcc6e16e] check-in: [032da543f0] user: drh branch: trunk, size: 41383)
02:49
Fix yet another issue with tables in side-by-side diffs - an off-by-one error this time. ... (file: [05126e9cd3] check-in: [de719b4396] user: drh branch: trunk, size: 40661)
02:43
Fix another bug in table handling for side-by-side diffs. ... (file: [c143bfc750] check-in: [db1365bc3b] user: drh branch: trunk, size: 40661)
00:22
Bug fix in the handling of tabs on a side-by-side diff. ... (file: [63328e7277] check-in: [07a0ade926] user: drh branch: trunk, size: 40547)
2012-02-04
21:09
Merge the retro-sbsdiff changes into trunk. ... (file: [a4789c5f45] check-in: [72c0183ac8] user: drh branch: trunk, size: 40529)
2011-10-22
13:29
Tweak the command-line side-by-side diff output so that it deals sanely with \r and \f characters. ... (file: [db8561a4f8] check-in: [4092208afc] user: drh branch: trunk, size: 41151)
03:37
Rework the side-by-side diff so that it handles tab characters. Fix an off-by-one error in the line numbers of side-by-side diffs. ... (file: [c352a38e9b] check-in: [8670373321] user: drh branch: trunk, size: 41084)
2011-10-21
23:44
Improved formatting for command-line side-by-side diff. Extend command-line side-by-side diff to all diff operations, including stash diffs. ... (file: [0f3e5f6bb9] check-in: [ab47cc73d7] user: drh branch: trunk, size: 40365)
21:55
Merge the side-by-side diff spacing bug fix into trunk. ... (file: [8c837f1701] check-in: [54e730c339] user: drh branch: trunk, size: 39444)
21:34
Merge the diff enhancements into trunk. ... (file: [7e89d5aed4] check-in: [c244605862] user: drh branch: trunk, size: 39443)
2011-10-20
14:50
Change strcpy() to memcpy() inside diff.c to avoid compiler warnings on OpenBSD. ... (file: [52714538a2] check-in: [06e9863cb0] user: drh branch: trunk, size: 33540)
2011-10-19
19:54
Merge in the annotatecmd_fix branch. ... (file: [6a9672991a] check-in: [e161670939] user: drh branch: trunk, size: 33537)
2011-10-17
01:19
Merge the side-by-side diff code into trunk. ... (file: [34c60666c8] check-in: [0bde74ea1e] user: drh branch: trunk, size: 33190)
2011-10-15
10:17
A very simple fix to the annotate memory leak problem. ... (file: [44fc8779b0] check-in: [9929bab702] user: drh branch: trunk, size: 28145)
2011-09-14
18:08
Merge the refactored permission flags into trunk. ... (file: [c57cf060da] check-in: [b344d3c0cd] user: drh branch: trunk, size: 28167)
11:14
Merge documentation updates from the msw-docco branch into trunk. ... (file: [949f21b722] check-in: [2210be19cc] user: drh branch: trunk, size: 28161)
2011-06-07
15:51
Improvements to the "annotate" algorithm: Only search primary ancestors; ignore branchs. ... (file: [5dfb1d6ff8] check-in: [621be70494] user: drh branch: trunk, size: 28151)
2011-06-01
22:32
In contexts where only a check-out makes since, only resolve tags or branch names into check-outs, not events or other artifacts. Ticket [5f611295e3c2a8]. ... (file: [7cdb9de46d] check-in: [2a013f0228] user: drh branch: trunk, size: 28078)
2011-05-20
11:32
Merge the windows-i18n branch into the trunk. ... (file: [8229499656] check-in: [d8ec765fac] user: drh branch: trunk, size: 28067)
2011-05-11
21:43
Add the --filevers option to the "annotate" command and the "filevers" query parameter to the "annotate" web method. This was used to help analyze the problem described by ticket [f91862eed367] ... (file: [17eaeee2d3] check-in: [c8f10e551e] user: drh branch: trunk, size: 28025)
2011-05-06
16:32
Improvements to the annotation algorithm so that if a line changes from X to Y then back to X, the annotation shows the second X not the first. Ticket [f0f9aff371f26] ... (file: [bcb2dbb5a1] check-in: [73c38a3add] user: drh branch: trunk, size: 27396)
14:36
Add --limit and --log options to the "annotate" command and corresponding query parameters to the web annotation interface. Part of the investigation of ticket [f0f9aff371f26b4] ... (file: [1069ab9c4d] check-in: [bd36723c3d] user: drh branch: trunk, size: 27068)
2011-04-15
15:36
Use a target= field on the hyperlink of the annotation web page. ... (file: [d9bd197c10] check-in: [0e477a48e5] user: drh branch: trunk, size: 25607)
2011-03-08
22:13
Fix diffs from or to an empty file to use the special position marker 0,0. Makes "fossil diff -N" create patches that are accepted by patch. ... (file: [a413ab030c] check-in: [4e77507e70] user: joerg branch: trunk, size: 25582)
2010-12-16
14:46
Use relative URLs for hyperlinks whereever possible, so that Fossil can work better behind a reverse proxy. ... (file: [4ed3cdb38c] check-in: [daeb10f65f] user: drh branch: trunk, size: 25327)
2010-10-15
17:13
Replace all malloc() calls with fossil_malloc(). The fossil_malloc() routine panics rather than return a NULL pointer. ... (file: [de7d2a7150] check-in: [8f41b2fa75] user: drh branch: trunk, size: 25331)
2010-10-14
19:14
Remove all use of ctypes.h in order to avoid compiler warnings and other problems associated with changing locales. ... (file: [1e36fe673f] check-in: [2fac809165] user: drh branch: trunk, size: 25497)
18:38
Work towards including full text of deleted and added files in a diff when the -N or --new-file option is used. Ticket [e90d38c2054e9b44792eb] ... (file: [14b976d07e] check-in: [585360b47d] user: drh branch: trunk, size: 25490)
2010-09-18
15:16
Clearify the operation of the "fossil annotate" command in the built-in help. Ticket [a182bd01a9c8dde66b1f] ... (file: [eff6dcec76] check-in: [bb1b3fa928] user: drh branch: trunk, size: 25441)
2010-08-21
17:32
Use a more precise (though slower) diff algorithm when working with small strings whose differences are hard to detect. ... (file: [dded333413] check-in: [1e08452c65] user: drh branch: trunk, size: 25438)
04:06
The command-line "diff" does not ignore whitespace at the end of lines and it generates a well-formed patch file that can be fed directly into "patch -p 0". Ticket [a9f7b23c2e376af]. GUI diffs and the merge commands do ignore end-of-line whitespace. ... (file: [3c77ae51b5] check-in: [5ef7435ac0] user: drh branch: trunk, size: 23163)
03:33
Change the built-in "diff" so that it no longer ignores whitespace at the end of lines, as doing so confuses the "patch" command. Ticket [a9f7b23c2e376af5b0] ... (file: [3c68c9ab1a] check-in: [7f788bdb04] user: drh branch: trunk, size: 22977)
2010-05-16
19:08
Change from GPL to the Simplified BSD License. ... (file: [dc52154079] check-in: [c06edd231f] user: drh branch: clear-title, size: 22815)
2010-04-02
20:09
Merge all recent trunk changes into the clear-title branch (since we hold clear title on all recent changes.) ... (file: [ab12301267] check-in: [64541535d9] user: drh branch: clear-title, size: 23091)
2010-01-19
14:15
Show the edited user id in annotations. ... (file: [6039c71513] check-in: [e7efca9ee9] user: drh branch: trunk, size: 23007)
2009-12-18
20:15
Add an "annotate" command to the command-line to suppliment the "annotate" web page. ... (file: [189451b157] check-in: [73b7faa58b] user: drh branch: trunk, size: 22971)
2009-08-28
22:59
Deleted some obsolete "todo" files. Updated the FAQ. Modified the the "vinfo" page to show check-in differences and made "vinfo" the default display for check-ins instead of "vdiff". ... (file: [423e7bd7db] check-in: [713b8be852] user: drh branch: trunk, size: 21686)
2008-05-16
18:11
Progress toward getting ticket handling to work. ... (file: [cebb8ba99c] check-in: [68c24b1857] user: drh branch: trunk, size: 21569)
2008-05-05
20:18
Work toward making the "h" permission mean "hyperlink". Without "h", many pages will display, but there are few hyperlinks. A message invites users to login as anonymous. ... (file: [626c13bd4e] check-in: [2b0d4519dc] user: drh branch: trunk, size: 21567)
2008-02-08
21:23
Improvements to annotated diffs - now takes into account contributions from other branches. ... (file: [a8aca97812] check-in: [840699ecd9] user: drh branch: trunk, size: 21463)
17:22
Avoid showing a short block of unchanged code at the end of a unified diff. ... (file: [fa6ef41ff5] check-in: [ba433cc4fc] user: drh branch: trunk, size: 22834)
2008-02-04
18:28
Add support for annotation in the web interface. ... (file: [464a37e277] check-in: [eae7ddfa4e] user: drh branch: trunk, size: 22831)
16:39
Begin inserting code to implement an "annotate" command. ... (file: [f5f8837cf7] check-in: [9b68bc33bd] user: drh branch: trunk, size: 20047)
14:24
Additional cleanup in the differencing engine. The new "dir" webpage now uses name= instead of the d= for the query parameter. ... (file: [06ee9b8f1e] check-in: [e81cc91aa4] user: drh branch: trunk, size: 15568)
14:05
Improvements to comments on the diff algorithm code. Completely remove the older Wagner/Myers algorithm which had been commented out. ... (file: [7a0eb09931] check-in: [eeea77f340] user: drh branch: trunk, size: 15579)
13:53
Tweaks to the diff algorithm give a 4x performance increase. Now comparable to command-line diff. ... (file: [50ab9d9846] check-in: [e8cf0061cc] user: drh branch: trunk, size: 24670)
2008-02-03
01:36
Merged importer to mainline. ... (file: [62a5d65904] check-in: [0523983440] user: aku branch: trunk, size: 23745)
2007-12-05
08:07
Merged mainline into my branch to get the newest application. ... (file: [ec5d799613] check-in: [d0305b305a] user: aku branch: trunk, size: 14111)
2007-07-21
14:10
Initial check-in of m1 sources. ... (file: [43924b3721] check-in: [dbda8d6ce9] user: drh branch: trunk, size: 5661)