NAME tcp —trivially copy a file SYNOPSIS tcp source target DESCRIPTION The tcp utility copies the contents of the source to target. If target is a directory, tcp will copy source into this directory. EXAMPLES The following examples show common usage: tcp file1 file2 tcp file1 dir tcp file1 dir/file2 tcp file1 dir/subdir/subsubdir/file2 EXIT STATUS tcp exits 0 on success, and >0 if an error occurred. SEE ALSO tcpm(1), lseek(2), read(2), write(2) NOTES The code for the tcp utility is, of course, well-formatted and can be compiled using the -Wall flags without any errors or warnings. NAME tcpm—trivially copy a file via mmap/memcpy SYNOPSIS tcpm source target DESCRIPTION The tcpm utility copies the contents of the source to target. That is, behaves entirely the same as tcp(1). Unlike tcp(1), tcpm uses mmap(2) and memcpy(2) instead of read(2) and write(2), which is why it can be rewarded with up to 10 extra credit points. EXAMPLES The following examples show common usage: tcpm file1 file2 tcpm file1 dir tcpm file1 dir/file2 tcpm file1 dir/subdir/subsubdir/file2 EXIT STATUS tcpm exits 0 on success, and >0 if an error occurred. SEE ALSO tcp(1),lseek(2),mmap(2),memcpy(2) NOTES The code for the tcpm utility is, of course, well-formatted and can be compiled using the -Wall flags without any errors or warnings.











- 1


- 粉丝: 35
- 资源: 20
我的内容管理 展开
我的资源 快来上传第一个资源
我的收益
登录查看自己的收益我的积分 登录查看自己的积分
我的C币 登录后查看C币余额
我的收藏
我的下载
下载帮助


