If the image of the curve has measure 0, it seems true. Indeed it is enough to prove that both the real and imaginary part are harmonic. This will be true if they satisfy the mean value identity on small balls.
The mean value identity is clear outside of $C$; on points of $C$ it follows by continuity and the fact that the integral of $f$ on $C$ with respect to the $2$-dimensional Lebesgue measure is $0$.
EDIT: I'm sorry, according to Mohan Ramachandran comment below, this answer is wrong.