Date: Wed, 1 Aug 2007 00:50:12 GMT From: Robert Noland <rnoland@2hip.net> To: freebsd-ports-bugs@FreeBSD.org Subject: Re: ports/114819: [patch] x11-toolkits/swt-devel crashes in realpath when invoke FileDialog Message-ID: <200708010050.l710oCAq093156@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR ports/114819; it has been noted by GNATS. From: Robert Noland <rnoland@2hip.net> To: bug-followup@FreeBSD.org Cc: Subject: Re: ports/114819: [patch] x11-toolkits/swt-devel crashes in realpath when invoke FileDialog Date: Tue, 31 Jul 2007 20:46:58 -0400 --=-llyEvLDhoTDM1ll8U2fG Content-Type: text/plain Content-Transfer-Encoding: quoted-printable arg, try that again... =3D=3D=3D> Updating from CVS ? swt-fix.diff M Makefile A files/patch-os.c =3D=3D=3D> Generating patch =3D=3D=3D> Viewing diff with less ? swt-fix.diff Index: Makefile =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/ports/x11-toolkits/swt-devel/Makefile,v retrieving revision 1.7 diff -u -r1.7 Makefile --- Makefile 20 Jul 2007 23:47:37 -0000 1.7 +++ Makefile 31 Jul 2007 21:29:03 -0000 @@ -7,6 +7,7 @@ =20 PORTNAME=3D swt-devel DISTVERSION=3D 3.3 +PORTREVISION=3D 1 PORTEPOCH=3D 1 CATEGORIES=3D x11-toolkits devel java MASTER_SITES=3D ${MASTER_SITE_ECLIPSE} Index: files/patch-os.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: files/patch-os.c diff -N files/patch-os.c --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ files/patch-os.c 31 Jul 2007 21:29:03 -0000 @@ -0,0 +1,22 @@ +--- os.c.orig 2007-07-31 17:17:38.000000000 -0400 ++++ os.c 2007-07-31 17:21:59.000000000 -0400 +@@ -17397,11 +17397,18 @@ + jint rc =3D 0; + OS_NATIVE_ENTER(env, that, realpath_FUNC); + if (arg0) if ((lparg0 =3D (*env)->GetByteArrayElements(env, arg0, NULL)) =3D=3D NULL) goto fail; +- if (arg1) if ((lparg1 =3D (*env)->GetByteArrayElements(env, arg1, NULL)) =3D=3D NULL) goto fail; ++ if (arg1) { ++ if ((lparg1 =3D (*env)->GetByteArrayElements(env, arg1, NULL)) =3D=3D NULL) goto fail; ++ } else { ++ lparg1 =3D malloc(PATH_MAX); ++ } + rc =3D (jint)realpath((const char *)lparg0, (char *)lparg1); + fail: + if (arg1 && lparg1) (*env)->ReleaseByteArrayElements(env, arg1, lparg1, 0); + if (arg0 && lparg0) (*env)->ReleaseByteArrayElements(env, arg0, lparg0, 0); ++ if (!arg1 && lparg1 && rc =3D=3D 0) ++ free(lparg1); ++ + OS_NATIVE_EXIT(env, that, realpath_FUNC); + return rc; + } =3D=3D=3D> Done --=-llyEvLDhoTDM1ll8U2fG Content-Type: application/pgp-signature; name=signature.asc Content-Description: This is a digitally signed message part -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (FreeBSD) iD8DBQBGr9gCM4TrQ4qfROMRAniHAJwM66yIe9i5/kBpZAEfRYQo4wQzkwCfUtsN qizPNO+a3k8bjqU9Awk2qvE= =jrs0 -----END PGP SIGNATURE----- --=-llyEvLDhoTDM1ll8U2fG--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200708010050.l710oCAq093156>