The four-fifths law for third-order longitudinal moments is examined, by the use of direct numerical simulation data on three-dimensional forced incompressible magnetohydrodynamic (MHD) turbulence without a uniformly imposed magnetic field in a periodic box. The magnetic Prandtl number is set to one, and the number of grid points is $512^3$. A generalized Karman-Howarth-Kolmogorov equation for second-order velocity moments in isotropic MHD turbulence is extended to anisotropic MHD turbulence by means of a spherical average over the direction of $textbf{r}$. Here, $textbf{r}$ is a separation vector. The viscous, forcing, anisotropy and nonstationary terms in the generalized equation are quantified. It is found that the influence of the anisotropic terms on the four-fifths law is negligible at small scales, compared to that of the viscous term. However, the influence of the directional anisotropy, which is measured by the departure of the third-order moments in a particular direction of $textbf{r}$ from the spherically averaged ones, on the four-fifths law is suggested to be substantial, at least in the case studied here.