Eric Blake <[EMAIL PROTECTED]> wrote: ... >> /* Construct a string NEW_DEST by concatenating DEST, a slash, and >> - basename(SOURCE) in alloca'd memory. Don't modify DEST or SOURCE. */ >> + basename (SOURCE) in alloca'd memory. Don't modify DEST or SOURCE. >> + Omit unnecessary slashes in the boundary between DEST and SOURCE in >> + the result; they can cause harm if "/" and "//" denote different >> + directories. */ >> >> #define FILE_BASENAME_CONCAT(new_dest, dest, source) >> \ > > Why not fix this to malloc instead of alloca, since on platforms (like > Hurd) that accept arbitrarily long filenames, alloca will cause problems > on long names?
IMHO, it's not worth it, since the only use is to concatenate the destination directory and the basename of a source file name, both of which were specified on the command line. But if someone submits a clean patch, I'll consider it. _______________________________________________ Bug-coreutils mailing list Bug-coreutils@gnu.org http://lists.gnu.org/mailman/listinfo/bug-coreutils