We investigated the long-term evolution of the spatial and velocity distribution of a planetesimal swarm around a protoplanet, calculating gas drag force and gravitational force of the protoplanet. Mutual scattering between planetesimals is taken into account, which removes the effect of mean motion resonances with the protoplanet. We simulated orbital evolution of 2000 planetesimals around a protoplanet for ∼105 years and found that scattering by a protoplanet, coupled with the gas drag, cleans up planetesimals in the feeding zone of the protoplanet. Our results show that planetesimals are trapped outside the feeding zone without the help of resonances. Sufficiently small planetesimals, on which the gas drag effectively acts, can remain in the feeding zone. We obtained the trapping condition in this nonresonance case. It is almost the same as the condition obtained by Kary et al. (1993, Icarus 106, 288-307), who considered "resonance trapping." Our results mean that the trapping of planetesimals does not depend on the strength of resonances against mutual scattering between planetesimals. Furthermore, the cleanup of the planetesimals occurs rapidly, so that the protoplanet cannot feed most of the planetesimals before the cleanup and growth of the protoplanet will slow down. That is, the effect of gas drag halts rather than prompts protoplanet growth by supply of material due to radial migration. We also examined the multiple-protoplanet case and considered the effect of gas on the formation of protoplanets.