+import os
from cStringIO import StringIO
import urlparse, httplib
import allmydata # for __full_version__
c.putheader("Connection", "close")
old = body.tell()
- body.seek(0, 2)
+ body.seek(0, os.SEEK_END)
length = body.tell()
body.seek(old)
c.putheader("Content-Length", str(length))