GNU bug report logs -
#58291
29.0.50; MacOS compilation warning for possibly unitialized use in emacs.c
Previous Next
Reported by: Gerd Möllmann <gerd.moellmann <at> gmail.com>
Date: Tue, 4 Oct 2022 15:27:01 UTC
Severity: normal
Found in version 29.0.50
Done: Stefan Kangas <stefankangas <at> gmail.com>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 58291 in the body.
You can then email your comments to 58291 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#58291
; Package
emacs
.
(Tue, 04 Oct 2022 15:27:01 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Gerd Möllmann <gerd.moellmann <at> gmail.com>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Tue, 04 Oct 2022 15:27:01 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
In GNU Emacs 29.0.50 (build 5, aarch64-apple-darwin21.6.0, NS
appkit-2113.60 Version 12.6 (Build 21G115)) of 2022-10-04 built on
Mini.fritz.box
Repository revision: 849b7756fd31a69791e67dfe010b1e10f0168c83
Repository branch: master
Windowing system distributor 'Apple', version 10.3.2113
System Description: macOS 12.6
This is latest master as of writing this. When compiling emacs, I see
emacs.c:899:7: warning: variable 'bufsize' is used uninitialized whenever 'if' condition is true [-Wsometimes-uninitialized]
if (!(emacs_executable && *emacs_executable))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
emacs.c:964:7: note: uninitialized use occurs here
if (bufsize < needed)
^~~~~~~
emacs.c:899:3: note: remove the 'if' if its condition is always false
if (!(emacs_executable && *emacs_executable))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
emacs.c:928:3: note: variable 'bufsize' is declared here
ptrdiff_t bufsize = exenamelen + strlen (suffix) + 1;
^
emacs.c:1755:17: warning: 'fork' is deprecated: Use posix_spawn or fork [-Wdeprecated-declarations]
f = fork (); /* in orig */
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#58291
; Package
emacs
.
(Tue, 04 Oct 2022 18:41:01 GMT)
Full text and
rfc822 format available.
Message #8 received at 58291 <at> debbugs.gnu.org (full text, mbox):
Gerd Möllmann <gerd.moellmann <at> gmail.com> writes:
> This is latest master as of writing this. When compiling emacs, I see
>
> emacs.c:899:7: warning: variable 'bufsize' is used uninitialized whenever 'if' condition is true [-Wsometimes-uninitialized]
> if (!(emacs_executable && *emacs_executable))
> ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> emacs.c:964:7: note: uninitialized use occurs here
> if (bufsize < needed)
> ^~~~~~~
I guess this might be related to Andreas' recent fix? Added to the CCs.
Reply sent
to
Stefan Kangas <stefankangas <at> gmail.com>
:
You have taken responsibility.
(Tue, 04 Oct 2022 18:59:02 GMT)
Full text and
rfc822 format available.
Notification sent
to
Gerd Möllmann <gerd.moellmann <at> gmail.com>
:
bug acknowledged by developer.
(Tue, 04 Oct 2022 18:59:02 GMT)
Full text and
rfc822 format available.
Message #13 received at 58291-done <at> debbugs.gnu.org (full text, mbox):
Lars Ingebrigtsen <larsi <at> gnus.org> writes:
> Gerd Möllmann <gerd.moellmann <at> gmail.com> writes:
>
>> This is latest master as of writing this. When compiling emacs, I see
>>
>> emacs.c:899:7: warning: variable 'bufsize' is used uninitialized whenever 'if' condition is true [-Wsometimes-uninitialized]
>> if (!(emacs_executable && *emacs_executable))
>> ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> emacs.c:964:7: note: uninitialized use occurs here
>> if (bufsize < needed)
>> ^~~~~~~
>
> I guess this might be related to Andreas' recent fix? Added to the CCs.
This is fixed on emacs-28 and merged to master. Closing.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Wed, 02 Nov 2022 11:24:11 GMT)
Full text and
rfc822 format available.
This bug report was last modified 2 years and 281 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.