Show $\int_Af(x)\,dx=0$ for every measurable subset $A$ of $[0,1]$.
The Lebesgue measure is regular, and in particular outer regular. Therefore there exists a sequence $(O_n)$ of open measurable sets containing $A$ such that $\lambda(A)=\inf \lambda(O_n)$.
Then $\displaystyle \int_A f(x)\, \mathrm{d}x=\int_{O_n} f(x)\, \mathrm{d}x - \int_{O_n - A} f(x)\, \mathrm{d}x$.
Since $O_n$ is an open set of $\mathbb{R}$, it is a countable union of open intervals and $\int_{O_n} f(x)\, \mathrm{d}x=0$. By dominated convergence you can show that $\int_{O_n - A} f(x)\, \mathrm{d}x \to 0$: use the sequence of functions $f1_{O_n-A}$ dominated by $|f|$.