Opened 4 years ago
Last modified 12 months ago
#16257 new enhancement
wordexp is unsupported
Reported by: | ddevault | Owned by: | nobody |
---|---|---|---|
Priority: | normal | Milestone: | Unscheduled |
Component: | System/POSIX | Version: | R1/beta2 |
Keywords: | Cc: | davidkaroly | |
Blocked By: | Blocking: | ||
Platform: | All |
Description
Change History (4)
comment:1 by , 22 months ago
Cc: | added |
---|
comment:2 by , 22 months ago
comment:3 by , 22 months ago
It's worth noting that OpenBSD does not support wordexp at all (probably because there is no "safe" way to implement it; note the musl implementation invokes /bin/sh!) So I'm not entirely sure we should support it either.
comment:4 by , 22 months ago
yes the backtick handling in musl is not so nice
Version 0, edited 22 months ago by (next)
Note:
See TracTickets
for help on using tickets.
This should be easily adaptable from MUSL, see: https://git.musl-libc.org/cgit/musl/tree/src/misc/wordexp.c
However... MUSL wordexp implementation uses pipe2 which is non-POSIX (but it's there in most actual implementations like Linux, FreeBSD, Illumos, MUSL)
So if we want to be really careful then we should implement
_pipe2()
in libroot and use that fromwordexp
. Then we can exportpipe2()
from libbsd. Or just make a shortcut and definepipe2()
in libroot - the question is: do we think there might be open source POSIX software that wants to redefine pipe2.