Skip to content

Commit

Permalink
Initialized helper arrays at arpack wrapper to avoid warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
lisitsyn committed Oct 8, 2011
1 parent 884c74a commit e13b169
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
8 changes: 4 additions & 4 deletions src/shogun/mathematics/arpack_d.cpp
Expand Up @@ -115,8 +115,8 @@ void arpack_dsxupd(double* matrix, double* rhs_diag, int n, int nev, const char*
superlu_options_t options;
SuperLUStat_t stat;
mem_usage_t mem_usage;
int *perm_c, *perm_r, *etree;
double *R, *C;
int *perm_c=NULL, *perm_r=NULL, *etree=NULL;
double *R=NULL, *C=NULL;
if (mode==3)
{
perm_c = intMalloc(n);
Expand All @@ -130,8 +130,8 @@ void arpack_dsxupd(double* matrix, double* rhs_diag, int n, int nev, const char*
double rcond;
double rpg;
int slu_info;
double* slu_Bv;
double* slu_Xv;
double* slu_Bv=NULL;
double* slu_Xv=NULL;
#endif

// shift-invert mode init
Expand Down
8 changes: 4 additions & 4 deletions src/shogun/mathematics/arpack_s.cpp
Expand Up @@ -114,8 +114,8 @@ void arpack_ssxupd(float* matrix, float* rhs_diag, int n, int nev, const char* w
superlu_options_t options;
SuperLUStat_t stat;
mem_usage_t mem_usage;
int *perm_c, *perm_r, *etree;
float *R, *C;
int *perm_c=NULL, *perm_r=NULL, *etree=NULL;
float *R=NULL, *C=NULL;
if (mode==3)
{
perm_c = intMalloc(n);
Expand All @@ -129,8 +129,8 @@ void arpack_ssxupd(float* matrix, float* rhs_diag, int n, int nev, const char* w
float rcond;
float rpg;
int slu_info;
float* slu_Bv;
float* slu_Xv;
float* slu_Bv = NULL;
float* slu_Xv = NULL;
#endif

// shift-invert mode init
Expand Down

0 comments on commit e13b169

Please sign in to comment.