diff --git a/src/hydro/Gadget2/hydro_iact.h b/src/hydro/Gadget2/hydro_iact.h
index f92531bcce30d6c1461bb1366f88bc282a2747e7..d31b6be383b80a2698b63d27308f6fee9b23518f 100644
--- a/src/hydro/Gadget2/hydro_iact.h
+++ b/src/hydro/Gadget2/hydro_iact.h
@@ -51,7 +51,7 @@ __attribute__((always_inline)) INLINE static void runner_iact_density(
   float dv[3], curlvr[3];
 
   /* Get the masses. */
-  const float mi = pj->mass;
+  const float mi = pi->mass;
   const float mj = pj->mass;
 
   /* Get r and r inverse. */