jgit/org.eclipse.jgit.test/.settings
Thomas Wolf 76b76a6048 ApplyCommand: use byte arrays for text patches, not strings
Instead of converting the patch bytes to strings apply the patch on
byte level, like C git does. Converting the input lines and the hunk
lines from bytes to strings and then applying the patch based on
strings may give surprising results if a patch converts a text file
from one encoding to another. Moreover, in the end we don't know which
encoding to use to write the result.

Previous code just wrote the result as UTF-8, which forcibly changed
the encoding if the original input had some other encoding (even if the
patch had the same non-UTF-8 encoding). It was also wrong if the input
was UTF-8, and the patch should have changed the encoding to something
else.

So use ByteBuffers instead of Strings. This has the additional advantage
that all these ByteBuffers can share the underlying byte arrays of the
input and of the patch, so it also reduces memory consumption.

Change-Id: I450975f2ba0e7d0bec8973e3113cc2e7aea187ee
Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
2021-05-26 00:38:00 +02:00
..
edu.umd.cs.findbugs.core.prefs [spotbugs] Silence CN_IMPLEMENTS_CLONE_BUT_NOT_CLONEABLE in jgit tests 2020-12-22 10:53:00 +01:00
org.eclipse.core.resources.prefs ApplyCommand: use byte arrays for text patches, not strings 2021-05-26 00:38:00 +02:00
org.eclipse.core.runtime.prefs Fix line endings 2010-06-18 23:36:18 +02:00
org.eclipse.jdt.core.prefs Ignore missing javadoc tags in test bundles 2020-11-29 20:16:38 +01:00
org.eclipse.jdt.ui.prefs Partially revert c0ad77d8 "Enhance Eclipse save actions" 2017-08-30 03:07:18 +02:00
org.eclipse.mylyn.tasks.ui.prefs Use commit message best practices for Mylyn Commit template 2011-09-05 23:57:21 +02:00
org.eclipse.mylyn.team.ui.prefs Fix Mylyn commit message template 2018-09-23 04:11:58 -04:00
org.eclipse.pde.api.tools.prefs Ignore warning for minor version change without API change 2017-11-24 01:12:14 +01:00
org.eclipse.pde.core.prefs Harmonize the JDT settings within JGit 2012-11-16 10:25:45 -08:00
org.eclipse.pde.prefs Ignore warning that tests don't export all packages 2019-06-16 02:34:48 +02:00