diff --git a/src/USER-DPD/fix_shardlow.cpp b/src/USER-DPD/fix_shardlow.cpp
index 2b7a69503acd37062d60094399f40da30bd23831..cee67cfcf96ee84ec5752de69d09b3651157879d 100644
--- a/src/USER-DPD/fix_shardlow.cpp
+++ b/src/USER-DPD/fix_shardlow.cpp
@@ -530,10 +530,9 @@ while (ct-- > 0) {
 void FixShardlow::initial_integrate(int vflag)
 {
   int ii;
-  int *ilist;
 
-  int nlocal = atom->nlocal;
-  int nghost = atom->nghost;
+  const int nlocal = atom->nlocal;
+  const int nghost = atom->nghost;
 
   const bool useDPDE = (pairDPDE != NULL);
 
@@ -592,7 +591,6 @@ void FixShardlow::initial_integrate(int vflag)
   // Allocate memory for v_t0 to hold the initial velocities for the ghosts
   v_t0 = (double (*)[3]) memory->smalloc(sizeof(double)*3*nghost, "FixShardlow:v_t0");
 
-  ilist = list->ilist;
   dtsqrt = sqrt(update->dt);
 
   // process neighbors in the local AIR
diff --git a/src/USER-OMP/pair_lj_cut_coul_wolf_omp.cpp b/src/USER-OMP/pair_lj_cut_coul_wolf_omp.cpp
index f5dc03e36828c60e1e68c509be24ee4d5c679ee2..51574b2ee7d884f768ddd8635116bd0df842829a 100644
--- a/src/USER-OMP/pair_lj_cut_coul_wolf_omp.cpp
+++ b/src/USER-OMP/pair_lj_cut_coul_wolf_omp.cpp
@@ -83,7 +83,7 @@ void PairLJCutCoulWolfOMP::eval(int iifrom, int iito, ThrData * const thr)
   int i,j,ii,jj,jnum,itype,jtype;
   double qitmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fpair;
   double r,rsq,r2inv,r6inv,forcecoul,forcelj,factor_coul,factor_lj;
-  double prefactor,erfcc,erfcd,v_sh,dvdrr,e_self,qisq;
+  double prefactor,erfcc,erfcd,v_sh,dvdrr,e_self;
   int *ilist,*jlist,*numneigh,**firstneigh;
 
   evdwl = ecoul = 0.0;