Date: Sun, 05 Oct 2003 13:30:39 -0400 From: "Robert Ames" <robertames@hotmail.com> To: stable@freebsd.org Subject: 4.9-RC1 issues Message-ID: <BAY7-F64nZhaD7GNSfE0000bdf1@hotmail.com>
next in thread | raw e-mail | index | archive | help
[-- Attachment #1 --] For what it's worth... 1. You cannot do a recursive rcp to a 4.9-RC1 machine. For example, "rcp -r somedir testbox:/tmp" fails. The attached patch fixes this. 2. Only the dial picobsd build will compile. The others (bridge, isp, net and router) all fail at various points. _________________________________________________________________ Get MSN 8 Dial-up Internet Service FREE for one month. Limited time offer-- sign up now! http://join.msn.com/?page=dept/dialup [-- Attachment #2 --] --- rcp.c.orig Fri Aug 16 15:06:34 2002 +++ rcp.c Sat Oct 4 21:17:16 2003 @@ -589,7 +589,7 @@ off_t i, j, size; int amt, count, exists, first, mask, mode, ofd, omode; int setimes, targisdir, wrerrno = 0; - char ch, *cp, *np, *targ, *why, *vect[1], buf[BUFSIZ]; + char ch, *cp, *np, *targ, *why, *vect[1], buf[BUFSIZ], path[PATH_MAX]; #define atime tv[0] #define mtime tv[1] @@ -686,21 +686,15 @@ if (*cp++ != ' ') SCREWUP("size not delimited"); if (targisdir) { - static char *namebuf = NULL; - static size_t cursize; - size_t need; - - need = strlen(targ) + strlen(cp) + 250; - if (need > cursize) { - if (namebuf != NULL) - free(namebuf); - if (!(namebuf = malloc(need))) - run_err("%s", strerror(errno)); - cursize = need; + if (strlen(targ) + (*targ ? 1 : 0) + strlen(cp) + >= sizeof(path)) { + run_err("%s%s%s: name too long", targ, + *targ ? "/" : "", cp); + exit(1); } - (void)snprintf(namebuf, need, "%s%s%s", targ, + (void)snprintf(path, sizeof(path), "%s%s%s", targ, *targ ? "/" : "", cp); - np = namebuf; + np = path; } else np = targ; exists = stat(np, &stb) == 0;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?BAY7-F64nZhaD7GNSfE0000bdf1>
