<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/libgit2.git/src/crlf.c, branch ethomson/diff_file</title>
<subtitle>github.com: libgit2/libgit2.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/'/>
<entry>
<title>crlf: set a safe crlf default</title>
<updated>2016-07-24T20:10:30+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@github.com</email>
</author>
<published>2016-07-24T20:10:30+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=df87648ab87f99a7cc53bdabc8aceb01e6771dac'/>
<id>df87648ab87f99a7cc53bdabc8aceb01e6771dac</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>crlf: do not ignore GIT_PASSTHROUGH error</title>
<updated>2016-02-23T10:50:23+00:00</updated>
<author>
<name>Patrick Steinhardt</name>
<email>ps@pks.im</email>
</author>
<published>2016-02-22T12:33:48+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=2129d6df93ba0ad5b2f7cf15d4e3cfa39487d5a0'/>
<id>2129d6df93ba0ad5b2f7cf15d4e3cfa39487d5a0</id>
<content type='text'>
When no payload is set for `crlf_apply` we try to compute the
crlf attributes ourselves with `crlf_check`. When the function
determines that the current file does not require any treatment
we return the GIT_PASSTHROUGH error code without actually
allocating the out-pointer, which indicates the file should not
be passed through the filter.

The `crlf_apply` function explicitly checks for the
GIT_PASSTHROUGH return code and ignores it. This means we will
try to apply the crlf-filter to the current file, leading us to
dereference the unallocated payload-pointer.

Fix this obviously incorrect behavior by not treating
GIT_PASSTHROUGH in any special way. This is the correct thing to
do anyway, as the code indicates that the file should not be
passed through the filter.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When no payload is set for `crlf_apply` we try to compute the
crlf attributes ourselves with `crlf_check`. When the function
determines that the current file does not require any treatment
we return the GIT_PASSTHROUGH error code without actually
allocating the out-pointer, which indicates the file should not
be passed through the filter.

The `crlf_apply` function explicitly checks for the
GIT_PASSTHROUGH return code and ignores it. This means we will
try to apply the crlf-filter to the current file, leading us to
dereference the unallocated payload-pointer.

Fix this obviously incorrect behavior by not treating
GIT_PASSTHROUGH in any special way. This is the correct thing to
do anyway, as the code indicates that the file should not be
passed through the filter.
</pre>
</div>
</content>
</entry>
<entry>
<title>crlf: give Unix the glory of autocrlf=true</title>
<updated>2015-06-22T16:00:30+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@edwardthomson.com</email>
</author>
<published>2015-06-09T00:42:28+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=146d0d084ea06527038e27549a8d4724d4fe5022'/>
<id>146d0d084ea06527038e27549a8d4724d4fe5022</id>
<content type='text'>
Perform LF-&gt;CRLF for core.autocrlf=true on non-Win32 because core
git does.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Perform LF-&gt;CRLF for core.autocrlf=true on non-Win32 because core
git does.
</pre>
</div>
</content>
</entry>
<entry>
<title>crlf: use statistics to control to workdir filter</title>
<updated>2015-06-22T16:00:19+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@microsoft.com</email>
</author>
<published>2015-06-08T19:58:54+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=47e9a6cb0573aa2190ddabadb94c0a89ae14ba52'/>
<id>47e9a6cb0573aa2190ddabadb94c0a89ae14ba52</id>
<content type='text'>
Use statistics (like core git) to control the behavior of the
to workdir CRLF filter.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use statistics (like core git) to control the behavior of the
to workdir CRLF filter.
</pre>
</div>
</content>
</entry>
<entry>
<title>git_filter_opt_t -&gt; git_filter_flag_t</title>
<updated>2015-02-19T16:09:54+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@microsoft.com</email>
</author>
<published>2015-02-19T16:09:54+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=795eaccd667ce24c290b6211ca0c6a84f84e7c2b'/>
<id>795eaccd667ce24c290b6211ca0c6a84f84e7c2b</id>
<content type='text'>
For consistency with the rest of the library, where an opt is an
options *structure*.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
For consistency with the rest of the library, where an opt is an
options *structure*.
</pre>
</div>
</content>
</entry>
<entry>
<title>Check for OOM</title>
<updated>2014-12-30T10:33:40+00:00</updated>
<author>
<name>Jacques Germishuys</name>
<email>jacquesg@striata.com</email>
</author>
<published>2014-12-27T19:04:28+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=dfda1cf507f91b53e73345c9053f6a61587db984'/>
<id>dfda1cf507f91b53e73345c9053f6a61587db984</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Update text=auto / core.autocrlf=false behavior</title>
<updated>2014-06-24T17:46:32+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@microsoft.com</email>
</author>
<published>2014-06-18T21:54:32+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=d412165f948b77bf548234fd46fb0743f6afc3ed'/>
<id>d412165f948b77bf548234fd46fb0743f6afc3ed</id>
<content type='text'>
Git for Windows 1.9.4 changed the behavior when the text=auto
attribute is specified and core.autocrlf=false.  Previous observed
behavior would *not* filter files when going into the working
directory, the new behavior *does* filter.  Update our behavior to match.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Git for Windows 1.9.4 changed the behavior when the text=auto
attribute is specified and core.autocrlf=false.  Previous observed
behavior would *not* filter files when going into the working
directory, the new behavior *does* filter.  Update our behavior to match.
</pre>
</div>
</content>
</entry>
<entry>
<title>Just don't CRLF filter if there are no CRs</title>
<updated>2014-05-19T22:05:39+00:00</updated>
<author>
<name>Russell Belfer</name>
<email>rb@github.com</email>
</author>
<published>2014-05-19T22:05:39+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=c094197bf92736bb1c40cf1ca87bda970ab7f999'/>
<id>c094197bf92736bb1c40cf1ca87bda970ab7f999</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Make core.safecrlf work on LF-ending platforms</title>
<updated>2014-05-19T21:57:09+00:00</updated>
<author>
<name>Russell Belfer</name>
<email>rb@github.com</email>
</author>
<published>2014-05-19T21:57:09+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=16798d08cf3a1757deb9f0363b35fbf775cfc3fb'/>
<id>16798d08cf3a1757deb9f0363b35fbf775cfc3fb</id>
<content type='text'>
If you enabled core.safecrlf on an LF-ending platform, we would
error even for files with all LFs.  We should only be warning on
irreversible mappings, I think.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If you enabled core.safecrlf on an LF-ending platform, we would
error even for files with all LFs.  We should only be warning on
irreversible mappings, I think.
</pre>
</div>
</content>
</entry>
<entry>
<title>Add filter options and ALLOW_UNSAFE</title>
<updated>2014-05-06T23:01:49+00:00</updated>
<author>
<name>Russell Belfer</name>
<email>rb@github.com</email>
</author>
<published>2014-05-06T23:01:49+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=5269008cf632efcd6a16f6160ec44244ce442400'/>
<id>5269008cf632efcd6a16f6160ec44244ce442400</id>
<content type='text'>
Diff and status do not want core.safecrlf to actually raise an
error regardless of the setting, so this extends the filter API
with an additional options flags parameter and adds a flag so that
filters can be applied with GIT_FILTER_OPT_ALLOW_UNSAFE, indicating
that unsafe filter application should be downgraded from a failure
to a warning.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Diff and status do not want core.safecrlf to actually raise an
error regardless of the setting, so this extends the filter API
with an additional options flags parameter and adds a flag so that
filters can be applied with GIT_FILTER_OPT_ALLOW_UNSAFE, indicating
that unsafe filter application should be downgraded from a failure
to a warning.
</pre>
</div>
</content>
</entry>
</feed>
