Opened 13 years ago

Closed 13 years ago

Last modified 13 years ago

#322 closed defect (fixed)

`cp` seems to produce a corrupted copy on a non-root fat

Reported by: Jakub Jermář Owned by: Jakub Jermář
Priority: major Milestone: 0.4.3
Component: helenos/app/bdsh Version:
Keywords: Cc:
Blocker for: Depends on:
See also:

Description

Mounting a non-root FAT file system over TMPFS root and doing:

/tmp # cp /readme /data/a
/tmp # ls /data/a
/tmp # cat /data/a

will result in the corrupted contents of /data/a. The reported file size will be correct, but the last few tens of bytes will look like duplicated from the beginning of the file.

Change History (4)

comment:1 by Jakub Jermář, 13 years ago

Not reproducible if the root FS is FAT too.

comment:2 by Jakub Jermář, 13 years ago

Component: fs/fatapp/bdsh

This is actually a problem of the bdsh implementation of cp. If the write() needs to be done multiple times during the copy, it is essential to move the buffer address according to the bytes written. Already fixed in lp:~jakub/helenos/fs.

comment:3 by Jakub Jermář, 13 years ago

Resolution: fixed
Status: newclosed

Fix merged in changeset:mainline,890.

comment:4 by Jakub Jermář, 13 years ago

Milestone: 0.5.00.4.3
Note: See TracTickets for help on using tickets.