Transport of gas across liquid films between bubbles is cited as one reason why CO2 foams for enhanced oil recovery (EOR) are usually weaker than N2 foams and why steam foams are weaker than foams of steam mixed with N2. We examine here the effect of inter-bubble gas diffusion on flowing bubbles in a simplified model of a porous medium (a periodically constricted tube in 2D) and in particular its effect on the bubble-size distribution and capillary resistance to flow. Bubbles somewhat smaller than a pore disappear by diffusion as the bubbles move. For bubbles larger than a pore, as expected in EOR, diffusion does not affect bubble size. Instead, diffusion actually increases capillary resistance to flow (i.e. makes foam stronger): lamellae spend more time in positions where lamella curvature resists movement. When fit to pressures and diffusion and convection rates representative of field application of foams, diffusion is not expected to alter the bubble-size distribution in a foam, but instead modestly increases the resistance to flow. The reason for the apparent weakness of CO2 foam therefore evidently lies in factors other than CO2's large diffusion rate through foam.