diff --git a/AMDiS/src/Mesh.cc b/AMDiS/src/Mesh.cc
index a7f7862834e3deec6f16799abbfa5ca80a140711..9e3233e5cb347b72dab2c7d615778f1caf13bf0b 100644
--- a/AMDiS/src/Mesh.cc
+++ b/AMDiS/src/Mesh.cc
@@ -602,28 +602,21 @@ namespace AMDiS {
     TEST_EXIT_DBG(position >= CENTER && position <= FACE)
       ("unknown position %d\n", position);
 
-    int ndof = nDof[position];
-    if (ndof) {
-      if (!dof) {
-	MSG("dof = NULL, but ndof = %d\n", ndof);
-	return;
-      }
+    if (nDof[position]) {
+      TEST_EXIT_DBG(dof != NULL)("dof = NULL, but ndof = %d\n", nDof[position]);
     } else  {
-      if (dof)
-	MSG("dof != NULL, but ndof = 0\n");
-
-      return;
+      TEST_EXIT_DBG(dof == NULL)("dof != NULL, but ndof = 0\n");
     }
 
-    TEST_EXIT_DBG(ndof <= MAX_DOF)
-      ("ndof too big: ndof = %d, MAX_DOF = %d\n", ndof, MAX_DOF);
+    TEST_EXIT_DBG(nDof[position] <= MAX_DOF)
+      ("ndof too big: ndof = %d, MAX_DOF = %d\n", nDof[position], MAX_DOF);
 
     for (unsigned int i = 0; i < admin.size(); i++) {
       int n = admin[i]->getNumberOfDofs(position);
       int n0 = admin[i]->getNumberOfPreDofs(position);
       
-      TEST_EXIT_DBG(n + n0 <= ndof)
-	("n = %d, n0 = %d too large: ndof = %d\n", n, n0, ndof);
+      TEST_EXIT_DBG(n + n0 <= nDof[position])
+	("n = %d, n0 = %d too large: ndof = %d\n", n, n0, nDof[position]);
       
       for (int j = 0; j < n; j++)
 	admin[i]->freeDofIndex(dof[n0 + j]);      
diff --git a/AMDiS/src/parallel/MeshDistributor.cc b/AMDiS/src/parallel/MeshDistributor.cc
index 82410faf7401a81042f38d17681b907e21dfd1b6..7823e1f14abe8a772c79909e6a9caad3540da2ac 100644
--- a/AMDiS/src/parallel/MeshDistributor.cc
+++ b/AMDiS/src/parallel/MeshDistributor.cc
@@ -1318,8 +1318,9 @@ namespace AMDiS {
 
 
     // === Add new macro elements to mesh. ===
-    TEST_EXIT(mesh->getGeo(FACE) || mesh->getGeo(CENTER))
-      ("Mh, dass macht dann doch noch etwas Arbeit f�r den Thomas!\n");
+    TEST_EXIT_DBG(feSpaces.size() == 1)("Not yet implemented!\n");
+    TEST_EXIT_DBG(feSpaces[0]->getBasisFcts()->getDegree() == 1)
+      ("Not yet implemented!\n");
 
     for (std::set<MacroElement*>::iterator it = newMacroEl.begin();
 	 it != newMacroEl.end(); ++it) {
@@ -1336,9 +1337,6 @@ namespace AMDiS {
       for (int i = 0; i < mesh->getGeo(VERTEX); i++)
 	mel->getElement()->setDof(i, mesh->getDof(VERTEX));
 
-      for (int i = 0; i < mesh->getGeo(EDGE); i++)
-	mel->getElement()->setDof(mesh->getGeo(VERTEX) + i, mesh->getDof(EDGE));
-
       // Push the macro element to all macro elements in mesh.
       mesh->getMacroElements().push_back(mel);
     }
@@ -1372,8 +1370,8 @@ namespace AMDiS {
       stdMpi.recv(it->first);
     stdMpi.startCommunication();
 
-    if (interchangeVectors.size() == 0)
-      WARNING("There are no interchange vectors defined!\n");
+    TEST_EXIT(interchangeVectors.size() > 0)
+       ("There are no interchange vectors defined!\n");
 
     StdMpi<vector<vector<double> > > stdMpi2(mpiComm, true);
     stdMpi2.send(sendValues);
diff --git a/AMDiS/src/parallel/MeshManipulation.cc b/AMDiS/src/parallel/MeshManipulation.cc
index a5d291297f792d2e8f17b63d7c43a04c23911024..fbdcd9d6665b3694e96356178f9836428cf2b1f8 100644
--- a/AMDiS/src/parallel/MeshManipulation.cc
+++ b/AMDiS/src/parallel/MeshManipulation.cc
@@ -157,8 +157,7 @@ namespace AMDiS {
 	      dofPosIndex[dofs0[i]] = dofGeoIndex0[i];
 
 	      TEST_EXIT_DBG(dofGeoIndex0[i] == dofGeoIndex1[i])
-		("Should not happen: %d %d\n", 
-		 dofGeoIndex0[i], dofGeoIndex1[i]);
+		("Should not happen: %d %d\n", dofGeoIndex0[i], dofGeoIndex1[i]);
 	    }
 
 	    break;
@@ -190,17 +189,24 @@ namespace AMDiS {
 	    BoundaryObject b0(el0, 0, FACE, i, reverseMode);
 	    BoundaryObject b1(el1, 0, FACE, elIt->ithObject, false);
 
-	    DofContainer dofs0, dofs1;	    
-	    el0->getAllDofs(feSpace, b0, dofs0, true);
-	    el1->getAllDofs(feSpace, b1, dofs1, true);
+	    DofContainer dofs0, dofs1;
+	    vector<GeoIndex> dofGeoIndex0, dofGeoIndex1;
+	    el0->getAllDofs(feSpace, b0, dofs0, true, &dofGeoIndex0);
+	    el1->getAllDofs(feSpace, b1, dofs1, true, &dofGeoIndex1);
 
 #if (DEBUG != 0)
-	    debug::testDofsByCoords(feSpace, dofs0, dofs1);
+	    if (feSpaces.size() == 1)
+	      debug::testDofsByCoords(feSpace, dofs0, dofs1);
+	    else 
+	      TEST_EXIT_DBG(dofs0.size() == dofs1.size())("Should not happen!\n");
 #endif
 
  	    for (unsigned int i = 0; i < dofs0.size(); i++) {
  	      mapDelDofs[dofs0[i]] = dofs1[i];
-	      dofPosIndex[dofs0[i]] = FACE;
+	      dofPosIndex[dofs0[i]] = dofGeoIndex1[i];
+
+	      TEST_EXIT_DBG(dofGeoIndex0[i] == dofGeoIndex1[i])
+		("Should not happen: %d %d\n", dofGeoIndex0[i], dofGeoIndex1[i]);
 	    }
 
 	    break;