Strange SD write behavior using sparkfun microSD shield and SD.h library

If you mean this shield, then you may be running out of power.

This card uses the 3.3v output of the Uno. That is max 50ma supply. The SanDisk cards require around 100ma to read and write. Here is another thread covering this.
http://arduino.cc/forum/index.php/topic,132303.0.html