]> git.rkrishnan.org Git - tahoe-lafs/tahoe-lafs.git/commitdiff
tidiness: return res from logging of progress
authorZooko O'Whielacronx <zooko@zooko.com>
Mon, 2 Apr 2007 17:23:24 +0000 (10:23 -0700)
committerZooko O'Whielacronx <zooko@zooko.com>
Mon, 2 Apr 2007 17:23:24 +0000 (10:23 -0700)
src/allmydata/encode_new.py

index f449176c4262bb632eae2477f5c47d5f4c3443e4..a0e929229812ae522f6739e926b0c7452e0859a4 100644 (file)
@@ -222,7 +222,10 @@ class Encoder(object):
             subshare_hash = hashutil.tagged_hash("encoded subshare", subshare)
             self.subshare_hashes[shareid].append(subshare_hash)
         dl = defer.DeferredList(dl)
-        dl.addCallback(lambda res: log.msg("%s uploaded %s / %s bytes of your file." % (self, self.segment_size*(segnum+1), self.segment_size*self.num_segments)))
+        def _logit(res):
+            log.msg("%s uploaded %s / %s bytes of your file." % (self, self.segment_size*(segnum+1), self.segment_size*self.num_segments))
+            return res
+        dl.addCallback(_logit)
         return dl
 
     def send_subshare(self, shareid, segment_num, subshare):