Mesh gets deformed when an array of spheres deformed along a curve :(
One of the easiest ways to make an object be duplicated along a Curve (path) is by parenting the object to the curve using (Follow Path):
1- Make sure the object and the curve's origins are at the same position, better to have the curve's origin at the beginning of the animation flow. Select the object then the curve, you need the curve to be the active selection.
2- Press Ctrl + P, choose Follow Path, this is different that Follow Path constraint, the only common thing is the name.
3- Select the object, go to Object menu, under Duplication, choose Frames and un-check Speed.
4- Select the curve, go to Curve menu, under Path Animation, set the amount of frames, the object will be duplicated according to this amount, check Follow, if you want your objects orientation to follow the curve.