An asymptotic formula is proved for the number of lattice points in large threedimensional convex bodies. In contrast to the usual assumption the Gaussian curvature of the boundary may vanish at non-isolated points. It is only assumed that the second fundamental form vanishes at isolated points where the tangent plane is rational and some ellipticity condition holds.