From 8c522b6f3a8fa7285497226b8190784a146524c6 Mon Sep 17 00:00:00 2001 From: jiri Date: Sun, 2 Apr 2006 19:38:20 +0000 Subject: [PATCH] *** empty log message *** --- sparsemat.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sparsemat.cc b/sparsemat.cc index a179211..74a8683 100644 --- a/sparsemat.cc +++ b/sparsemat.cc @@ -881,7 +881,7 @@ void NRVec::gemv(const T beta, const SparseMat &a, const char trans, const { if((trans=='n'?a.ncols():a.nrows())!= (SPMatindex)x.size()) laerror("incompatible sizes in gemv"); copyonwrite(); -if(beta!=(T)0) (*this) *= beta; +if(beta!=(T)0) {if(beta!=(T)1) (*this) *= beta;} else memset(v,0,nn*sizeof(T)); bool transp = tolower(trans)!='n'; //not OK for complex