diff --git a/factory/FLINTconvert.cc b/factory/FLINTconvert.cc
index c36f6022d..67c271c5a 100644
--- a/factory/FLINTconvert.cc
+++ b/factory/FLINTconvert.cc
@@ -652,7 +652,7 @@ convertFacCFMatrix2Fq_nmod_mat_t (fq_nmod_mat_t M,
   {
     for(j=m.columns();j>0;j--)
     {
-      convertFacCF2nmod_poly_t (M->rows[i-1]+j-1, m (i,j));
+      convertFacCF2nmod_poly_t (fq_nmod_mat_entry (M, i-1, j-1), m (i,j));
     }
   }
 }
diff --git a/libpolys/polys/flintconv.cc b/libpolys/polys/flintconv.cc
index 89152f5e4..56d527c16 100644
--- a/libpolys/polys/flintconv.cc
+++ b/libpolys/polys/flintconv.cc
@@ -331,7 +331,7 @@ void convSingMFlintFq_nmod_mat(matrix m, fq_nmod_mat_t M, const fq_nmod_ctx_t fq
   {
     for(j=MATCOLS(m);j>0;j--)
     {
-      convSingPFlintnmod_poly_t (M->rows[i-1]+j-1, MATELEM(m,i,j),r);
+      convSingPFlintnmod_poly_t (fq_nmod_mat_entry (M, i-1, j-1), MATELEM(m,i,j),r);
     }
   }
 }
