The SD library has a bug in available() that will return zero even if more data is available.
http://code.google.com/p/arduino/issues/detail?id=571