[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
CP Bug Detected ?
From: |
Rivalino Matias Jr. |
Subject: |
CP Bug Detected ? |
Date: |
18 Sep 2003 23:27:30 -0300 |
Hi,
I got a problem in cp operation. When I copy a FILE to a device with
less space than the FILE size, I get the following behavior:
address@hidden root]# ls -l teste.zero
-rw-r--r-- 1 root root 172933632 Set 18 23:06 teste.zero
address@hidden root]# cp teste.zero ./teste.zero2
cp: writing `./teste.zero2': No space left on device
address@hidden root]# ls -l teste.zero*
-rw-r--r-- 1 root root 172933632 Set 18 23:06 teste.zero
-rw-r--r-- 1 root root 138993664 Set 18 23:08 teste.zero2
The cp doesn't remove the incomplete target file in this situation. So,
looking for a solution, I identified the point where need changes:
if (full_write (dest_desc, buf, n_read) < 0)
{
error (0, errno, _("writing %s"), quote (dst_path));
return_val = -1;
goto close_src_and_dst_desc;
}
I would like to get a feedback from you if the behavior described above
is a BUG. In case positive, I'd like to propose a patch.
I'm using fileutils-4.1 on Red Hat 9. Looking in a Conectiva 8 I got the
same with the same fileutils software installed.
Regards,
RMJ.
- CP Bug Detected ?,
Rivalino Matias Jr. <=