This is the mail archive of the gsl-discuss@sources.redhat.com mailing list for the GSL project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: LU_decomp segfault


"Matthew J. Doller" wrote:
>
> the offending code looks like this:
> 
> ...
>   int * interchange;
> ...
>   error = gsl_linalg_LU_decomp ( m , perm , interchange);
>   // ^^^^ segfault occurs here.  following printf is never reached.

The pointer 'interchange' is dangling. This should read

  int interchange;
  ...
  error = gsl_linalg_LU_decomp ( m, perm, &interchange );
  ...


That's probably the trouble.


-- 
G. Jungman


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]