blob: d4764f586736d5e7c37af2322cfea8f61dc462da [file] [log] [blame]
Patrick Williamsb48b7b42016-08-17 15:04:38 -05001Upstream-Status: Pending
2
3Subject: rcp: fix to work with large files
4
5When we copy file by rcp command, if the file > 2GB, it will fail.
6The cause is that it used incorrect data type on file size in sink() of rcp.
7
8Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
9---
10 src/rcp.c | 4 ++--
11 1 file changed, 2 insertions(+), 2 deletions(-)
12
13diff --git a/src/rcp.c b/src/rcp.c
14index 21f55b6..bafa35f 100644
15--- a/src/rcp.c
16+++ b/src/rcp.c
17@@ -876,9 +876,9 @@ sink (int argc, char *argv[])
18 enum
19 { YES, NO, DISPLAYED } wrerr;
20 BUF *bp;
21- off_t i, j;
22+ off_t i, j, size;
23 int amt, count, exists, first, mask, mode, ofd, omode;
24- int setimes, size, targisdir, wrerrno;
25+ int setimes, targisdir, wrerrno;
26 char ch, *cp, *np, *targ, *vect[1], buf[BUFSIZ];
27 const char *why;
28
29--
301.9.1
31