[patch] /bin/cp POSIX conformance

看板DFBSD_submit作者時間21年前 (2004/12/21 02:32), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串1/2 (看更多)
For the cp utility, IEEE Std 1003.1-2004 states the following under section 2d: 2. If source_file is of type directory, the following steps shall be taken: .... d. If dest_file exists and it is not of type directory, cp shall write a diagnostic message to standard error, do nothing more with source_file or any files below source_file in the file hierarchy, and go on to any remaining files. Currently, the cp utility exits with the diagnostic message. The patch below turns this into a warning, and also changes another warning to use the standard errno EISDIR. - Jason <http://www.smethers.net/~jason/patches/cp.c.diff1>
文章代碼(AID): #11nnge00 (DFBSD_submit)
文章代碼(AID): #11nnge00 (DFBSD_submit)