Commits

Anonymous committed 1875be3

buffer strings in storage_object.py so that we don't send them 1 byte at a time.

  • Participants
  • Parent commits 67d667d

Comments (0)

Files changed (1)

cloudfiles/storage_object.py

         """
         self._name_check()
 
+        if isinstance(iterable, basestring):
+            # buffer it so that we don't send it 1 byte at a time.
+            iterable = StringIO.StringIO(iterable)
+
         if hasattr(iterable, 'read'):
 
             def file_iterator(file):