[Picante-commits] r146 - branches/gsoc/src

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Wed Jul 23 04:58:32 CEST 2008


Author: skembel
Date: 2008-07-23 04:58:32 +0200 (Wed, 23 Jul 2008)
New Revision: 146

Modified:
   branches/gsoc/src/picante.c
Log:
Change sizeof to doubles so trialswap doesn't crash

Modified: branches/gsoc/src/picante.c
===================================================================
--- branches/gsoc/src/picante.c	2008-07-23 02:33:00 UTC (rev 145)
+++ branches/gsoc/src/picante.c	2008-07-23 02:58:32 UTC (rev 146)
@@ -15,9 +15,9 @@
   int i,j;
   double **m;
 
-  m = (double **)R_alloc(row,sizeof(int *));
+  m = (double **)R_alloc(row,sizeof(double *));
   for (i=0; i<row; i++) {
-    m[i] = (double *)R_alloc(column,sizeof(int));
+    m[i] = (double *)R_alloc(column,sizeof(double));
     for (j=0; j<column; j++) {
       m[i][j] = v[row*j+i];  /* R uses column-first ordering */
     }



More information about the Picante-commits mailing list