Theorem: If p is a Gaussian prime and $p|zw$ for some gaussian integer $z,w \in Z[i]$ then $p|z$ or $p|w$.
Suppose $p \not| z$ and lets deduce $p | w$. Let $u$ be a greatest common divisor of $p, z$.
So $u = pt + zs$ for some $t,s \in Z[i]$ and $u |p$ and $u |z$. Write $p = uk$ for some $k$ in $Z[i]$. Since p is a Gaussian prime, one of $u$ or $k$ is a unit in $Z[i]$.
If $k$ is a unit, the $u=pk^{-1}$ where $k^{-1} \in Z[i]$, and we see that $p | u$. Since $u | z$ we get $p | z$ contrary to assumption.
Thus $u$ is a unit with inverse $u^{-1} \in Z[i]$. Then $wu = pwt + wzs$ and $w = pwtu^{-1} + wzsu^{-1}$ We see that $p | pwtu^{-1}$ and we are given that $p|wz$. So $p|w$
I don't get how the bold part concludes that $p | w$. Also for the theorem it says $p|z$ or $p|w$, why not the case $p | z$ and $p | w$?