Number of possible integer values of $x$ for which $\frac{x^3+2x^2+9}{x^2+4x+5}$ is integer How many integer numbers, $x$, verify that the following
\begin{equation*}
\frac{x^3+2x^2+9}{x^2+4x+5}
\end{equation*}
is an integer?
I managed to do:
\begin{equation*}
\frac{x^3+2x^2+9}{x^2+4x+5} = x-2 + \frac{3x+19}{x^2+4x+5}
\end{equation*}
but I cannot go forward.

Let $t=x+2$, then $$t^2+1\mid 3t+13$$ and thus $$t^2+1\mid t(3t+13)-3(t^2+1)= 13t-3$$
 so $$t^2+1\mid 13(3t+13)-3(13t-3) = 178$$
So $$t^2+1\in\{1,2,89,178\}\implies t=\pm 1,0 \implies x\in\{-1,-2,-3\}$$ 
