4. Let the function $f(x)$ have the domain $D=(-\infty, 0) \bigcup(0,+\infty)$, and for any $x \in D$, it holds that $f(x)=\frac{f(1) \cdot x^{2}+f(2) \cdot x-1}{x}$, then the sum of all zeros of $f(x)$ is $\qquad$ .
$$
\left\{\begin{array} { l } 
{ f ( 1 ) = f ( 1 ) + f ( 2 ) - 1 , } \\
{ f ( 2 ) = \frac { 4 f ( 1 ) + 2 f ( 2 ) - 1 } { 2 } }
\end{array} \Rightarrow \left\{\begin{array}{l}
f(1)=\frac{1}{4}, \\
f(2)=1
\end{array} \Rightarrow f(x)=\frac{x^{2}+4 x-4}{4 x} .\right.\right.
$$

So the sum of all zeros of $f(x)$ is -4.