mirror of
https://github.com/GoldenCheetah/GoldenCheetah.git
synced 2026-02-13 16:18:42 +00:00
Fix LM compiler warnings
.. they hide real issues.
This commit is contained in:
@@ -22,6 +22,9 @@
|
||||
#endif
|
||||
|
||||
|
||||
#pragma GCC diagnostic ignored "-Wimplicit-fallthrough"
|
||||
#pragma GCC diagnostic ignored "-Wcpp"
|
||||
|
||||
/* precision-specific definitions */
|
||||
#define LEVMAR_CHKJAC LM_ADD_PREFIX(levmar_chkjac)
|
||||
#define LEVMAR_FDIF_FORW_JAC_APPROX LM_ADD_PREFIX(levmar_fdif_forw_jac_approx)
|
||||
@@ -426,7 +429,7 @@ int info, rank, worksz, *iwork, iworksz;
|
||||
static int LEVMAR_LUINVERSE(LM_REAL *A, LM_REAL *B, int m)
|
||||
{
|
||||
void *buf=NULL;
|
||||
int buf_sz=0;
|
||||
//int buf_sz=0;
|
||||
|
||||
register int i, j, k, l;
|
||||
int *idx, maxi=-1, idx_sz, a_sz, x_sz, work_sz, tot_sz;
|
||||
@@ -439,7 +442,7 @@ LM_REAL *a, *x, *work, max, sum, tmp;
|
||||
work_sz=m;
|
||||
tot_sz=(a_sz + x_sz + work_sz)*sizeof(LM_REAL) + idx_sz*sizeof(int); /* should be arranged in that order for proper doubles alignment */
|
||||
|
||||
buf_sz=tot_sz;
|
||||
//buf_sz=tot_sz;
|
||||
buf=(void *)malloc(tot_sz);
|
||||
if(!buf){
|
||||
fprintf(stderr, RCAT("memory allocation in ", LEVMAR_LUINVERSE) "() failed!\n");
|
||||
|
||||
@@ -32,6 +32,7 @@ void lmcurve_evaluate(
|
||||
const double *const par, const int m_dat, const void *const data,
|
||||
double *const fvec, int *const info)
|
||||
{
|
||||
(void)(info);
|
||||
for (int i = 0; i < m_dat; i++ )
|
||||
fvec[i] =
|
||||
((lmcurve_data_struct*)data)->y[i] -
|
||||
|
||||
Reference in New Issue
Block a user