I got stuck with the following while going through Lemma $3.20$ from the book 'Ergodic Theory, Independence and Dichotomies' by Kerr and Li.

**Problem:** Let $(X,\mu)$ be a probability measure space, and let $g\in L^2(X)$. If for all $h_1,h_2\in L^{\infty}(X)$ with $\|h_1\|_2,\|h_2\|_2\leq 1$, there exists a constant $c$ (independent of $h_1$ and $h_2$) such that $|\langle gh_1,h_2\rangle|\leq c$, then prove that $g\in L^{\infty}(X)$.

Thanks in advance for any help or suggestion.