<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/patch.git/src/util.c, branch baserock/morph</title>
<subtitle>git.savannah.gnu.org: git/patch.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/patch.git/'/>
<entry>
<title>maint: update all copyright year number ranges</title>
<updated>2012-01-01T09:26:02+00:00</updated>
<author>
<name>Jim Meyering</name>
<email>meyering@redhat.com</email>
</author>
<published>2012-01-01T09:26:02+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/patch.git/commit/?id=2d38b11799be79a2a141181689a889bd5bee25da'/>
<id>2d38b11799be79a2a141181689a889bd5bee25da</id>
<content type='text'>
Run "make update-copyright".
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Run "make update-copyright".
</pre>
</div>
</content>
</entry>
<entry>
<title>build: update to latest gnulib and adapt</title>
<updated>2011-12-14T15:34:45+00:00</updated>
<author>
<name>Jim Meyering</name>
<email>meyering@redhat.com</email>
</author>
<published>2011-10-09T09:40:42+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/patch.git/commit/?id=5cb38ce3903b5c33750cd52f983a8f68f945c7dd'/>
<id>5cb38ce3903b5c33750cd52f983a8f68f945c7dd</id>
<content type='text'>
Mark functions as pure of const, per recommendations enabled by
new gcc -W options.  Apply _GL_ATTRIBUTE_PURE and _GL_ATTRIBUTE_CONST.
* src/common.h: Apply new function attributes.
* src/pch.c: Likewise.
* src/pch.h: Likewise.
* src/util.c: Likewise.
* src/util.h: Likewise.
* configure.ac: Use -Wno-format-nonliteral.
* m4/.gitignore: Update.
* gnulib: Update to latest.
* cfg.mk: Exempt src/util.c from two tests, to avoid new
"make syntax-check" failures.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Mark functions as pure of const, per recommendations enabled by
new gcc -W options.  Apply _GL_ATTRIBUTE_PURE and _GL_ATTRIBUTE_CONST.
* src/common.h: Apply new function attributes.
* src/pch.c: Likewise.
* src/pch.h: Likewise.
* src/util.c: Likewise.
* src/util.h: Likewise.
* configure.ac: Use -Wno-format-nonliteral.
* m4/.gitignore: Update.
* gnulib: Update to latest.
* cfg.mk: Exempt src/util.c from two tests, to avoid new
"make syntax-check" failures.
</pre>
</div>
</content>
</entry>
<entry>
<title>Timestamp not set when creating files with --set-time or --set-utc</title>
<updated>2011-12-08T23:53:38+00:00</updated>
<author>
<name>Andreas Gruenbacher</name>
<email>agruen@linbit.com</email>
</author>
<published>2011-12-08T23:53:38+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/patch.git/commit/?id=5ca55b84143a840218bcdc78120b44b02d8ef561'/>
<id>5ca55b84143a840218bcdc78120b44b02d8ef561</id>
<content type='text'>
* src/util.h (enum file_attributes): Add FA_XATTRS flag for extended
attributes.
* src/patch.c (main): Use set_file_attributes() even when the infile doesn't
exist: it may still set the file time (FA_TIMES).  Omit all other FA_ flags if
infile doesn't exist.  Otherwise, add FA_XATTRS as well.
* src/util.c (set_file_attributes): Only copy extended attributes if FA_XATTRS
is set.  Avoid using st where it may be undefined.
* tests/preserve-mode-and-timestamp: Add file create test.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* src/util.h (enum file_attributes): Add FA_XATTRS flag for extended
attributes.
* src/patch.c (main): Use set_file_attributes() even when the infile doesn't
exist: it may still set the file time (FA_TIMES).  Omit all other FA_ flags if
infile doesn't exist.  Otherwise, add FA_XATTRS as well.
* src/util.c (set_file_attributes): Only copy extended attributes if FA_XATTRS
is set.  Avoid using st where it may be undefined.
* tests/preserve-mode-and-timestamp: Add file create test.
</pre>
</div>
</content>
</entry>
<entry>
<title>emit one more diagnostic with the required "program_name: " prefix</title>
<updated>2011-05-25T14:47:33+00:00</updated>
<author>
<name>Jim Meyering</name>
<email>meyering@redhat.com</email>
</author>
<published>2011-05-24T13:51:51+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/patch.git/commit/?id=0649fbf212224f757245263e5f3c90e423b21571'/>
<id>0649fbf212224f757245263e5f3c90e423b21571</id>
<content type='text'>
* src/util.c: Include "error.h".
(ask): Use error, not perror.  The latter would not have included
the usual "program name: " prefix.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* src/util.c: Include "error.h".
(ask): Use error, not perror.  The latter would not have included
the usual "program name: " prefix.
</pre>
</div>
</content>
</entry>
<entry>
<title>remove side effect from assert</title>
<updated>2011-05-25T14:47:33+00:00</updated>
<author>
<name>Jim Meyering</name>
<email>meyering@redhat.com</email>
</author>
<published>2011-05-24T13:35:50+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/patch.git/commit/?id=209af7ee4b7d28a25b0fb33c7e017277291cfc2c'/>
<id>209af7ee4b7d28a25b0fb33c7e017277291cfc2c</id>
<content type='text'>
* src/util.c (parse_c_string): Don't increment "s" in assert.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* src/util.c (parse_c_string): Don't increment "s" in assert.
</pre>
</div>
</content>
</entry>
<entry>
<title>explicitly ignore close return value to placate static analyzers</title>
<updated>2011-05-25T14:47:33+00:00</updated>
<author>
<name>Jim Meyering</name>
<email>meyering@redhat.com</email>
</author>
<published>2011-05-24T11:29:46+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/patch.git/commit/?id=bb2fef06eb52eefe0d72d6e536cd928565dcdcd0'/>
<id>bb2fef06eb52eefe0d72d6e536cd928565dcdcd0</id>
<content type='text'>
* src/util.c: Include "ignore-value.h".
(ask): Use ignore_value to tell tools that yes, we really do
mean to ignore any close failure on this error path.
* bootstrap.conf (gnulib_modules): Add ignore-value.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* src/util.c: Include "ignore-value.h".
(ask): Use ignore_value to tell tools that yes, we really do
mean to ignore any close failure on this error path.
* bootstrap.conf (gnulib_modules): Add ignore-value.
</pre>
</div>
</content>
</entry>
<entry>
<title>plug a leak in fetchname</title>
<updated>2011-05-25T14:47:32+00:00</updated>
<author>
<name>Jim Meyering</name>
<email>meyering@redhat.com</email>
</author>
<published>2011-05-24T11:16:27+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/patch.git/commit/?id=6526aec61f0bd6ea49a412cd7898d0c0cf90092b'/>
<id>6526aec61f0bd6ea49a412cd7898d0c0cf90092b</id>
<content type='text'>
* src/util.c (fetchname): Don't leak "timestr" when returning early.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* src/util.c (fetchname): Don't leak "timestr" when returning early.
</pre>
</div>
</content>
</entry>
<entry>
<title>avoid a used-uninitialized error in fetchname</title>
<updated>2011-05-25T14:47:00+00:00</updated>
<author>
<name>Andreas Gruenbacher</name>
<email>agruen@linbit.com</email>
</author>
<published>2011-05-24T10:11:32+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/patch.git/commit/?id=b4c6b7086bd496bbc5b15de657247919a143e3b2'/>
<id>b4c6b7086bd496bbc5b15de657247919a143e3b2</id>
<content type='text'>
* src/util.c (fetchname): Avoid a used-uninitialized error.
Before, when "*t == '\n'", stamp.tv_nsec would have been
used undefined.  The fix is to set that member rather than
stamp.tv_sec, which is already set to the desired value.
This was reported by coverity.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* src/util.c (fetchname): Avoid a used-uninitialized error.
Before, when "*t == '\n'", stamp.tv_nsec would have been
used undefined.  The fix is to set that member rather than
stamp.tv_sec, which is already set to the desired value.
This was reported by coverity.
</pre>
</div>
</content>
</entry>
<entry>
<title>maint: remove now-unneeded macro definitions</title>
<updated>2011-03-27T07:19:46+00:00</updated>
<author>
<name>Jim Meyering</name>
<email>meyering@redhat.com</email>
</author>
<published>2011-03-10T07:44:13+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/patch.git/commit/?id=df2831fbdf3e61181a96324852e0a2a0fc6ae79a'/>
<id>df2831fbdf3e61181a96324852e0a2a0fc6ae79a</id>
<content type='text'>
* bootstrap.conf (gnulib_modules): Include gnulib's signal module,
so that signal.h guarantees definition of certain macros.
* src/util.c (SIG_BLOCK, SIG_UNBLOCK, SIG_SETMASK): Remove definition.
Now, gnulib guarantees that these are defined.
* src/common.h (SIZE_MAX): Likewise.
* cfg.mk (local-checks-to-skip): Enable the
sc_prohibit_always-defined_macros check, now that it passes.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* bootstrap.conf (gnulib_modules): Include gnulib's signal module,
so that signal.h guarantees definition of certain macros.
* src/util.c (SIG_BLOCK, SIG_UNBLOCK, SIG_SETMASK): Remove definition.
Now, gnulib guarantees that these are defined.
* src/common.h (SIZE_MAX): Likewise.
* cfg.mk (local-checks-to-skip): Enable the
sc_prohibit_always-defined_macros check, now that it passes.
</pre>
</div>
</content>
</entry>
<entry>
<title>Ignore dangerous filenames instead of failing immediately</title>
<updated>2011-02-16T11:01:19+00:00</updated>
<author>
<name>Andreas Gruenbacher</name>
<email>agruen@linbit.com</email>
</author>
<published>2011-02-16T10:57:57+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/patch.git/commit/?id=f663762bf0aa5089fee41d62a4e7528f436164d4'/>
<id>f663762bf0aa5089fee41d62a4e7528f436164d4</id>
<content type='text'>
* src/pch.c (name_is_valid): New function.
(intuit_diff_type, best_name): Use name_is_valid() here.
(strip_leading_slashes): Remove name validation tests from here.
* tests/bad-filenames: Add more tests for covering more of the
file name guessing corner cases in intuit_diff_type(), update the
existing tests.
* NEWS: Update.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* src/pch.c (name_is_valid): New function.
(intuit_diff_type, best_name): Use name_is_valid() here.
(strip_leading_slashes): Remove name validation tests from here.
* tests/bad-filenames: Add more tests for covering more of the
file name guessing corner cases in intuit_diff_type(), update the
existing tests.
* NEWS: Update.
</pre>
</div>
</content>
</entry>
</feed>
