Date: Sat, 31 Dec 2022 22:33:42 +0000 From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 268686] freebsd-update cannot handle spaces in file paths Message-ID: <bug-268686-227@https.bugs.freebsd.org/bugzilla/>
next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D268686 Bug ID: 268686 Summary: freebsd-update cannot handle spaces in file paths Product: Base System Version: 13.1-RELEASE Hardware: Any OS: Any Status: New Severity: Affects Some People Priority: --- Component: bin Assignee: bugs@FreeBSD.org Reporter: 06-birds-herald@icloud.com Created attachment 239169 --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=3D239169&action= =3Dedit Modifications to freebsd-update to make it work with spaces in the file pat= hs If freebsd-update is run with the -b -d or -f options followed by a path wi= th a space, freebsd-update prints its usage and exits instead of updating. This = is because it further splits arguments by spaces into more arguments internall= y, causing it to incorrectly parse them. There are also problems with the inte= rnal handling of the $BASEDIR and other path variables. This makes it difficult = to update certain installations, for example a jail located at a non-root loca= tion with a space in its path. This can be fixed by simply adding quotes to the necessary locations in the script, and changing the use of xargs in one location. I have attached a di= ff of what I had to do to get it to work for my usage (fetch, upgrade, and install). certctl, which is run by freebsd-update, also has a problem with spaces and would also need to be fixed in a similar manner. The script also doesn't return a nonzero error code upon failure to parse i= ts arguments. --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-268686-227>