Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 19 Mar 2002 01:46:56 +0000
From:      "J. Mallett" <jmallett@FreeBSD.ORG>
To:        "J. Mallett" <jmallett@FreeBSD.org>
Cc:        cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject:   Re: cvs commit: src/usr.bin/uudecode uudecode.c
Message-ID:  <20020319014655.GA9503@FreeBSD.ORG>
In-Reply-To: <200203190044.g2J0i7C35496@freefall.freebsd.org>
References:  <200203190044.g2J0i7C35496@freefall.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help

--oyUTqETQ0mS9luUI
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Mon, Mar 18, 2002 at 04:44:07PM -0800, J. Mallett wrote:
> jmallett    2002/03/18 16:44:07 PST
>=20
>   Modified files:
>     usr.bin/uudecode     uudecode.c=20
>   Log:
>   Make uudecode(1) use setmode(3) and getmode(3) instead of just blindly
>   chmodding using an octal mode, as uudecode needs to handle symbolic mod=
es
>   as chmod and such do.

I broke what was fixed in rev1.12, reported in PR 2882, which is uuencoding=
 to
a file name specified with a space in its name, by including a space in the
list of delimiters for strtok(3), here's a patch:

Index: uudecode.c
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
RCS file: /home/ncvs/src/usr.bin/uudecode/uudecode.c,v
retrieving revision 1.20
diff -u -r1.20 uudecode.c
--- uudecode.c  19 Mar 2002 00:44:07 -0000      1.20
+++ uudecode.c  19 Mar 2002 01:24:38 -0000
@@ -193,7 +193,7 @@
                        err(1, "strdup()");
        }
        if (!oflag) {
-               outfile =3D strtok(NULL, " \r\n");
+               outfile =3D strtok(NULL, "\r\n");
                if (outfile =3D=3D NULL)
                        errx(1, "no filename in input file");
        }

I'll commit it given mentor approval, or being told I don't need it in a
bug-fixing immediate followup commit.

Sorry,
	/j.

--oyUTqETQ0mS9luUI
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: 2.6.3ia

iQCVAwUBPJaYfIlNtGTEXmf1AQFf9AQAqDieztLiI3Eetu4HVfFfuxZ2Ci8mRXBH
omNBdUwCK5NgzVM5xme5Zkh2MBFMBiphmFtu9++O61BWv7DS1G3pTtaO6aEMepPS
vAVagzRKnCGwMnkxb85P+FxyuEWlWQVWRIyYkhszvcFqXXm5icFzhVGDE43g3ENJ
ToCPhbNDdSw=
=lp+g
-----END PGP SIGNATURE-----

--oyUTqETQ0mS9luUI--

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020319014655.GA9503>