<feed xmlns='http://www.w3.org/2005/Atom'>
<title>busybox-w32/scripts/basic/fixdep.c, branch cron_changes</title>
<subtitle>A mirror of https://github.com/rmyorston/busybox-w32.git
</subtitle>
<id>https://git.lua4.win/busybox-w32/atom?h=cron_changes</id>
<link rel='self' href='https://git.lua4.win/busybox-w32/atom?h=cron_changes'/>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/'/>
<updated>2024-09-28T07:13:32+00:00</updated>
<entry>
<title>Merge branch 'busybox' into merge</title>
<updated>2024-09-28T07:13:32+00:00</updated>
<author>
<name>Ron Yorston</name>
<email>rmy@pobox.com</email>
</author>
<published>2024-09-28T07:13:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=431e2704c17d5c0e51a0cbebfb1105bd4962b3f7'/>
<id>urn:sha1:431e2704c17d5c0e51a0cbebfb1105bd4962b3f7</id>
<content type='text'>
</content>
</entry>
<entry>
<title>fixdep: add fstat error handling</title>
<updated>2024-09-27T18:03:30+00:00</updated>
<author>
<name>Sam James</name>
<email>sam@gentoo.org</email>
</author>
<published>2024-04-23T20:10:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=480a07bd6828285628abbbe3fe8e5e3b25ce1a92'/>
<id>urn:sha1:480a07bd6828285628abbbe3fe8e5e3b25ce1a92</id>
<content type='text'>
When `fstat` fails, `st` is left uninitialised. In our case, Ben Kohler
noticed our release media builds were failing in Gentoo on x86 when building
busybox with occasional SIGBUS. This turned out to be EOVERFLOW (from 32-bit
ino_t) which wasn't being reported because nothing was checking the return value
from `fstat`.

Fix that to avoid UB (use of uninit var) and to give a more friendly
error to the user.

This actually turns out to be fixed already in the kernel from back in
2010 [0] and 2016 [1].

[0] https://github.com/torvalds/linux/commit/a3ba81131aca243bfecfa78c42edec0cd69f72d6
[1] https://github.com/torvalds/linux/commit/46fe94ad18aa7ce6b3dad8c035fb538942020f2b

Reported-by: Ben Kohler &lt;bkohler@gentoo.org&gt;
Signed-off-by: Sam James &lt;sam@gentoo.org&gt;
Signed-off-by: Denys Vlasenko &lt;vda.linux@googlemail.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'busybox' into merge</title>
<updated>2023-04-09T10:24:09+00:00</updated>
<author>
<name>Ron Yorston</name>
<email>rmy@pobox.com</email>
</author>
<published>2023-04-09T10:24:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=d9f2ea8628452f787e02dd0e496af612a2e94578'/>
<id>urn:sha1:d9f2ea8628452f787e02dd0e496af612a2e94578</id>
<content type='text'>
</content>
</entry>
<entry>
<title>fixdep: avoid underflow when end of entry doesn't coincide with EOF</title>
<updated>2023-02-27T12:09:44+00:00</updated>
<author>
<name>Arsen Arsenović</name>
<email>arsen@gentoo.org</email>
</author>
<published>2023-02-21T19:20:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=2d4a3d9e6c1493a9520b907e07a41aca90cdfd94'/>
<id>urn:sha1:2d4a3d9e6c1493a9520b907e07a41aca90cdfd94</id>
<content type='text'>
Bug: https://bugs.gentoo.org/893776
Closes: https://bugs.busybox.net/show_bug.cgi?id=15326
Signed-off-by: Arsen Arsenović &lt;arsen@gentoo.org&gt;
Signed-off-by: Denys Vlasenko &lt;vda.linux@googlemail.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'busybox' into merge</title>
<updated>2021-05-14T07:17:12+00:00</updated>
<author>
<name>Ron Yorston</name>
<email>rmy@pobox.com</email>
</author>
<published>2021-05-14T07:17:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=a3f5a1b7f4275f713acf22f534f95c0da8392e53'/>
<id>urn:sha1:a3f5a1b7f4275f713acf22f534f95c0da8392e53</id>
<content type='text'>
</content>
</entry>
<entry>
<title>fix "warning array subscript has type 'char'"</title>
<updated>2021-04-14T17:12:43+00:00</updated>
<author>
<name>Denys Vlasenko</name>
<email>vda.linux@googlemail.com</email>
</author>
<published>2021-04-14T17:12:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=1a45b2ccea94b0fc123798f276a0801413597880'/>
<id>urn:sha1:1a45b2ccea94b0fc123798f276a0801413597880</id>
<content type='text'>
Signed-off-by: Denys Vlasenko &lt;vda.linux@googlemail.com&gt;
</content>
</entry>
<entry>
<title>fixdep: fix assumption that `long` is as large as `void *`</title>
<updated>2017-07-14T12:47:31+00:00</updated>
<author>
<name>Johannes Schindelin</name>
<email>johannes.schindelin@gmx.de</email>
</author>
<published>2017-02-01T21:10:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=b41c851312876dbf146fb674265b86c72ed611ab'/>
<id>urn:sha1:b41c851312876dbf146fb674265b86c72ed611ab</id>
<content type='text'>
It is not. At least not in general. And in particular not on 64-bit
Windows, where sizeof(long) == 4.

What the code wanted to use is actually called intptr_t.

Note: `intptr_t` is a C99 feature.

Signed-off-by: Johannes Schindelin &lt;johannes.schindelin@gmx.de&gt;
</content>
</entry>
<entry>
<title>fixdep: be careful about handling empty lines correctly</title>
<updated>2017-07-14T12:47:31+00:00</updated>
<author>
<name>Johannes Schindelin</name>
<email>johannes.schindelin@gmx.de</email>
</author>
<published>2017-06-27T09:59:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=213b279baaae27a4285eb354f11e3c3b1986d129'/>
<id>urn:sha1:213b279baaae27a4285eb354f11e3c3b1986d129</id>
<content type='text'>
The current code without this patch is seriously flawed, as it can
easily overrun the buffer while looking for the *beginning* of the
line.

The symptom when trying to build without this patch in Git for
Windows' SDK (which is a special-purpose version of MSYS2) is:

$ make mingw64_defconfig &amp;&amp; make -j15
  HOSTCC  scripts/basic/fixdep
make[1]: *** [scripts/Makefile.host:104: scripts/basic/fixdep] Error 127
make: *** [Makefile:358: scripts_basic] Error 2
make: *** [Makefile:358: scripts_basic] Error 2

Signed-off-by: Johannes Schindelin &lt;johannes.schindelin@gmx.de&gt;
</content>
</entry>
<entry>
<title>fixdep: read the dependency files in binary mode</title>
<updated>2017-07-14T12:47:26+00:00</updated>
<author>
<name>Johannes Schindelin</name>
<email>johannes.schindelin@gmx.de</email>
</author>
<published>2017-06-27T09:57:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=32fb4fe097115b23914832d26dba4d1de62f5f17'/>
<id>urn:sha1:32fb4fe097115b23914832d26dba4d1de62f5f17</id>
<content type='text'>
We want to make sure that the original line endings are preserved, as
fixdep hardcodes the assumption of Unix-type line endings.

The symptom is this (kinda hard to understand) error when building in
Git for Windows' SDK (which is a special-purpose version of MSYS2):

$ make mingw64_defconfig &amp;&amp; make -j15
   HOSTCC  scripts/basic/fixdep
C:/git-sdk-64/mingw64/x86_64-w64-mingw32/include/ctype.h
64-w64-mingw32/include/ctype.h: Invalid argument
fixdep: make[1]: *** [scripts/Makefile.host:104: scripts/basic/fixdep] Error 2
make: *** [Makefile:358: scripts_basic] Error 2

Signed-off-by: Johannes Schindelin &lt;johannes.schindelin@gmx.de&gt;
</content>
</entry>
<entry>
<title>Merge branch 'busybox' into merge</title>
<updated>2014-01-13T09:11:24+00:00</updated>
<author>
<name>Ron Yorston</name>
<email>rmy@pobox.com</email>
</author>
<published>2014-01-13T09:11:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/busybox-w32/commit/?id=e6edcba4f2fc20a3e9db75ebe82d7a71094fe17c'/>
<id>urn:sha1:e6edcba4f2fc20a3e9db75ebe82d7a71094fe17c</id>
<content type='text'>
Conflicts:
	include/platform.h
	scripts/basic/fixdep.c
</content>
</entry>
</feed>
