public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libc/30759] New: Comment on SPAWN_ERROR is wrong
@ 2023-08-14 19:46 safinaskar at mail dot ru
2023-08-16 12:15 ` [Bug libc/30759] " adhemerval.zanella at linaro dot org
2023-08-16 14:25 ` safinaskar at mail dot ru
0 siblings, 2 replies; 3+ messages in thread
From: safinaskar at mail dot ru @ 2023-08-14 19:46 UTC (permalink / raw)
To: glibc-bugs
https://sourceware.org/bugzilla/show_bug.cgi?id=30759
Bug ID: 30759
Summary: Comment on SPAWN_ERROR is wrong
Product: glibc
Version: 2.40
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: libc
Assignee: unassigned at sourceware dot org
Reporter: safinaskar at mail dot ru
CC: drepper.fsp at gmail dot com
Target Milestone: ---
Consider
https://sourceware.org/git/?p=glibc.git;a=blob;f=sysdeps/unix/sysv/linux/spawni.c;h=ec687cb4238bac10a113ab924ea9b05500142b88;hb=1b214630ce6f7e0099b8b6f87246246739b079cf#l55
. The comment is wrong, because actual value of this macro (SPAWN_ERROR) in
fact is never used! Let me tell you why.
The only use site of this macro is
https://sourceware.org/git/?p=glibc.git;a=blob;f=sysdeps/unix/sysv/linux/spawni.c;h=ec687cb4238bac10a113ab924ea9b05500142b88;hb=1b214630ce6f7e0099b8b6f87246246739b079cf#l306
. But, as well as I understand in this place args->err is non-zero. Then in
parent we expect this args->err in line
https://sourceware.org/git/?p=glibc.git;a=blob;f=sysdeps/unix/sysv/linux/spawni.c;h=ec687cb4238bac10a113ab924ea9b05500142b88;hb=1b214630ce6f7e0099b8b6f87246246739b079cf#l417
. It is non-zero, so we fail to __waitpid. __waitpid doesn't save process
status, so the status (i. e. SPAWN_ERROR) is never observed.
So, I propose removing confusing comment. Also macro SPAWN_ERROR itself should
be removed, too. "_exit (SPAWN_ERROR)" should be replaced with "_exit(1) /*
This value is never observed */"
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug libc/30759] Comment on SPAWN_ERROR is wrong
2023-08-14 19:46 [Bug libc/30759] New: Comment on SPAWN_ERROR is wrong safinaskar at mail dot ru
@ 2023-08-16 12:15 ` adhemerval.zanella at linaro dot org
2023-08-16 14:25 ` safinaskar at mail dot ru
1 sibling, 0 replies; 3+ messages in thread
From: adhemerval.zanella at linaro dot org @ 2023-08-16 12:15 UTC (permalink / raw)
To: glibc-bugs
https://sourceware.org/bugzilla/show_bug.cgi?id=30759
Adhemerval Zanella <adhemerval.zanella at linaro dot org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Severity|normal |enhancement
CC| |adhemerval.zanella at linaro dot o
| |rg
Priority|P2 |P3
--- Comment #1 from Adhemerval Zanella <adhemerval.zanella at linaro dot org> ---
Agree, it makes sense. Could you send a patch to libc-alpha?
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug libc/30759] Comment on SPAWN_ERROR is wrong
2023-08-14 19:46 [Bug libc/30759] New: Comment on SPAWN_ERROR is wrong safinaskar at mail dot ru
2023-08-16 12:15 ` [Bug libc/30759] " adhemerval.zanella at linaro dot org
@ 2023-08-16 14:25 ` safinaskar at mail dot ru
1 sibling, 0 replies; 3+ messages in thread
From: safinaskar at mail dot ru @ 2023-08-16 14:25 UTC (permalink / raw)
To: glibc-bugs
https://sourceware.org/bugzilla/show_bug.cgi?id=30759
--- Comment #2 from Askar Safin <safinaskar at mail dot ru> ---
I don't want to do this
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-08-16 14:25 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-08-14 19:46 [Bug libc/30759] New: Comment on SPAWN_ERROR is wrong safinaskar at mail dot ru
2023-08-16 12:15 ` [Bug libc/30759] " adhemerval.zanella at linaro dot org
2023-08-16 14:25 ` safinaskar at mail dot ru
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).