How do I close a object with the curve modifier applied to it?
Select one end of the curve, then the second end (holding SHIFT) and press F button. It'll connect two ends.


Now choose the merged end, select the handle and press S. Hold SHIFT to precisely match two ends of the mesh.



This may although change a shape of a curve a bit. You may use the other method, which leaves the curve's shape as it is. First select the mesh, enter the Edit Mode and enable the 'use the modifier while in edit mode' option.


Now scale the mesh along the desired axis to match its ends precisely.


You may also select the Curve, then go to the Curve Data header and check the Stretch and Bounds Clamp checkboxes in the Shape panel.