From f7cf19e4caf990b468e043c1233b99046bfc5e70 Mon Sep 17 00:00:00 2001 From: David Date: Fri, 30 Dec 2016 11:38:32 -0600 Subject: [PATCH] fixed warnings, tested linux compatibility --- stim/envi/envi.h | 2 +- stim/math/matrix.h | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/stim/envi/envi.h b/stim/envi/envi.h index 0c62f80..6ae2416 100644 --- a/stim/envi/envi.h +++ b/stim/envi/envi.h @@ -664,7 +664,7 @@ public: ((bsq*)file)->bil(outfile, PROGRESS, OPTIMIZATION); else if(interleave == envi_header::BIP){ //ERROR //std::cout<<"ERROR: conversion from BSQ to BIP isn't practical; use BSQ->BIL->BIP instead"<*)file)->bip(outfile, PROGRESS, OPTIMIZATION); + ((bsq*)file)->bip(outfile, PROGRESS, OPTIMIZATION); //exit(1); } } diff --git a/stim/math/matrix.h b/stim/math/matrix.h index 402fe8a..21f63bb 100644 --- a/stim/math/matrix.h +++ b/stim/math/matrix.h @@ -233,11 +233,11 @@ public: int r, c, ri, cia, cib; T a = 0; T b = 0; - for (c = 0; c < C; c++) { + for (c = 0; c < (int)C; c++) { for (r = 0; r < R; r++) { ri = r; - cia = (r + c) % C; - cib = (C - 1 - r) % C; + cia = (r + c) % (int)C; + cib = ((int)C - 1 - r) % (int)C; a += get(ri, cia); b += get(ri, cib); } -- libgit2 0.21.4