|
From: <and...@us...> - 2013-06-27 08:02:51
|
Revision: 12391
http://sourceforge.net/p/plplot/code/12391
Author: andrewross
Date: 2013-06-27 08:02:46 +0000 (Thu, 27 Jun 2013)
Log Message:
-----------
Backport fix for java pltr2 crash to Debian packages.
Modified Paths:
--------------
trunk/debian/changelog
trunk/debian/patches/series
Added Paths:
-----------
trunk/debian/patches/java-pltr2-fix.diff
Modified: trunk/debian/changelog
===================================================================
--- trunk/debian/changelog 2013-06-27 06:50:34 UTC (rev 12390)
+++ trunk/debian/changelog 2013-06-27 08:02:46 UTC (rev 12391)
@@ -1,12 +1,14 @@
-plplot (5.9.9-7ubuntu2) UNRELEASED; urgency=low
+plplot (5.9.9-7) UNRELEASED; urgency=low
* debian/patches/fix-cmake-ada-support.diff: Update ada support from
upstream to ensure plplot builds with latest Ada compiler in unstable.
* debian/rules: Update python library path.
* debian/patches/fix-cmake-d-support.diff: Add patch from upstream to
fix D language support.
+ * debian/patches/java-pltr2-fix.diff: Add patch from upstream to fix
+ crash in java examples using pltr2 (closes: #713309).
- -- Andrew Ross <and...@us...> Wed, 26 Jun 2013 22:29:59 +0100
+ -- Andrew Ross <and...@us...> Thu, 27 Jun 2013 08:44:20 +0100
plplot (5.9.9-6) unstable; urgency=low
Added: trunk/debian/patches/java-pltr2-fix.diff
===================================================================
--- trunk/debian/patches/java-pltr2-fix.diff (rev 0)
+++ trunk/debian/patches/java-pltr2-fix.diff 2013-06-27 08:02:46 UTC (rev 12391)
@@ -0,0 +1,80 @@
+Description: Fix for crash in pltr2 with java bindings
+Author: Andrew Ross <and...@us...>
+Origin: upstream
+
+Index: plplot-5.9.9/bindings/java/plplotjavac.i
+===================================================================
+--- plplot-5.9.9.orig/bindings/java/plplotjavac.i 2011-10-13 01:43:01.000000000 +0100
++++ plplot-5.9.9/bindings/java/plplotjavac.i 2013-06-27 08:42:33.360546465 +0100
+@@ -330,6 +330,7 @@
+ static PLINT Xlen = 0, Ylen = 0;
+ static PLFLT **xg;
+ static PLFLT **yg;
++ static PLcGrid2 *cgrid;
+ %}
+
+ // The following typemaps take care of marshaling values into and out of PLplot functions. The
+@@ -1536,7 +1537,6 @@
+ int nx = ( *jenv )->GetArrayLength( jenv, $input );
+ int ny = -1;
+ int i, j;
+- PLcGrid2 cgrid;
+ ai = (jobject *) malloc( nx * sizeof ( jobject ) );
+ adat = (jPLFLT **) malloc( nx * sizeof ( jPLFLT * ) );
+
+@@ -1580,16 +1580,18 @@
+
+ free( adat );
+ free( ai );
+- cgrid.xg = xg;
+- cgrid.yg = yg;
+- cgrid.nx = nx;
+- cgrid.ny = ny;
+- $1 = &cgrid;
++ cgrid = (PLcGrid2 *) malloc( sizeof ( PLcGrid2 ) );
++ cgrid->xg = xg;
++ cgrid->yg = yg;
++ cgrid->nx = nx;
++ cgrid->ny = ny;
++ $1 = cgrid;
+ }
+
+ %typemap( freearg ) PLPointer OBJECT_DATA {
+ free( yg[0] );
+ free( yg );
++ free( cgrid );
+ }
+ %typemap( jni ) PLPointer OBJECT_DATA "jobjectArray"
+ %typemap( jtype ) PLPointer OBJECT_DATA jPLFLTbracket2
+@@ -1679,7 +1681,6 @@
+ int nx = ( *jenv )->GetArrayLength( jenv, $input );
+ int ny = -1;
+ int i, j;
+- PLcGrid2 cgrid;
+ ai = (jobject *) malloc( nx * sizeof ( jobject ) );
+ adat = (jPLFLT **) malloc( nx * sizeof ( jPLFLT * ) );
+
+@@ -1723,16 +1724,18 @@
+
+ free( adat );
+ free( ai );
+- cgrid.xg = xg;
+- cgrid.yg = yg;
+- cgrid.nx = nx;
+- cgrid.ny = ny;
+- $1 = &cgrid;
++ cgrid = (PLcGrid2 *) malloc( sizeof ( PLcGrid2 ) );
++ cgrid->xg = xg;
++ cgrid->yg = yg;
++ cgrid->nx = nx;
++ cgrid->ny = ny;
++ $1 = cgrid;
+ }
+
+ %typemap( freearg ) PLPointer OBJECT_DATA_img {
+ free( yg[0] );
+ free( yg );
++ free( cgrid );
+ }
+ %typemap( jni ) PLPointer OBJECT_DATA_img "jobjectArray"
+ %typemap( jtype ) PLPointer OBJECT_DATA_img jPLFLTbracket2
Property changes on: trunk/debian/patches/java-pltr2-fix.diff
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Modified: trunk/debian/patches/series
===================================================================
--- trunk/debian/patches/series 2013-06-27 06:50:34 UTC (rev 12390)
+++ trunk/debian/patches/series 2013-06-27 08:02:46 UTC (rev 12391)
@@ -8,3 +8,4 @@
fix-cmake-ada-support.diff
fix-lua-includes.diff
fix-cmake-d-support.diff
+java-pltr2-fix.diff
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|