diff --git a/dumux/boxmodels/co2/co2volumevariables.hh b/dumux/boxmodels/co2/co2volumevariables.hh
index b6a654ece45a49c5ac00613fa631a3bf69608dbb..7a3de6f12ecc52e31f2afbe329e623b929c0e467 100644
--- a/dumux/boxmodels/co2/co2volumevariables.hh
+++ b/dumux/boxmodels/co2/co2volumevariables.hh
@@ -60,8 +60,8 @@ class CO2VolumeVariables: public TwoPTwoCVolumeVariables<TypeTag>
 
     // present phases
     enum {
-        wPhaseOnly = Indices::lPhaseOnly,
-        nPhaseOnly = Indices::gPhaseOnly,
+        wPhaseOnly = Indices::wPhaseOnly,
+        nPhaseOnly = Indices::nPhaseOnly,
         bothPhases = Indices::bothPhases
     };
 
diff --git a/dumux/decoupled/2p2c/2p2cadaptiveproperties.hh b/dumux/decoupled/2p2c/2p2cadaptiveproperties.hh
index 87c3966de08479bcfc7177f22cf2967264c097ec..7ee1a32a03edcc62b2fc7b30bd553f2032c08b02 100644
--- a/dumux/decoupled/2p2c/2p2cadaptiveproperties.hh
+++ b/dumux/decoupled/2p2c/2p2cadaptiveproperties.hh
@@ -35,7 +35,7 @@ namespace Dumux
 
 //****** forward declarations  ******//
 template<class TypeTag>
-class DecoupledTwoPTwoCIndicesAdaptive;
+struct DecoupledTwoPTwoCIndicesAdaptive;
 
 ////////////////////////////////
 // properties
diff --git a/dumux/freeflow/stokes/stokesmodel.hh b/dumux/freeflow/stokes/stokesmodel.hh
index 228eb2a5e7212785a2395178f6e43a5e624f29c2..586fb1486fb1c5e8c0711a886403fe64aef37bd4 100644
--- a/dumux/freeflow/stokes/stokesmodel.hh
+++ b/dumux/freeflow/stokes/stokesmodel.hh
@@ -99,7 +99,6 @@ public:
     {
         GlobalPosition globalI, globalJ;
         PrimaryVariables tmpFlux(0.0);
-        int sign;
 
         FVElementGeometry fvGeometry;
         ElementVolumeVariables elemVolVars;
@@ -129,8 +128,6 @@ public:
                 continue;
 
             for (int i = 0; i < fvGeometry.numVertices; i++) {
-                const int &globalIdx =
-                    this->vertexMapper().map(*elemIt, i, dim);
                 const GlobalPosition &global = fvGeometry.subContVol[i].global;
                 if (globalI[axis] < coordVal)
                     flux += this->localResidual().residual(i);
diff --git a/test/boxmodels/co2/heterogeneousproblem.hh b/test/boxmodels/co2/heterogeneousproblem.hh
index dd5313acd937adda7f9cce4c90416bbe7689c56c..667a009c70642a3d3d11dec97d0682a4be0553de 100644
--- a/test/boxmodels/co2/heterogeneousproblem.hh
+++ b/test/boxmodels/co2/heterogeneousproblem.hh
@@ -469,7 +469,7 @@ public:
     int initialPhasePresence(const Vertex &vert,
                              int &globalIdx,
                              const GlobalPosition &globalPos) const
-    { return Indices::lPhaseOnly; }
+    { return Indices::wPhaseOnly; }
 
     // \}
 
diff --git a/test/boxmodels/co2ni/heterogeneousproblemni.hh b/test/boxmodels/co2ni/heterogeneousproblemni.hh
index c1a331bca0871cf4543f57e9fbea9d4eda1af5ad..66dbb08c095fe5fdd8312d6e37f7a297c251a2d8 100644
--- a/test/boxmodels/co2ni/heterogeneousproblemni.hh
+++ b/test/boxmodels/co2ni/heterogeneousproblemni.hh
@@ -475,7 +475,7 @@ public:
     int initialPhasePresence(const Vertex &vert,
                              int &globalIdx,
                              const GlobalPosition &globalPos) const
-    { return Indices::lPhaseOnly; }
+    { return Indices::wPhaseOnly; }
 
     // \}