Motion of charged particles along a magnetic neutral line. I. Diffusion