diff -r d0e8c542c38e -r 8a6b143057d7 gmyth-stream/server/0.3/lib/request_handler.py --- a/gmyth-stream/server/0.3/lib/request_handler.py Mon Aug 13 23:03:08 2007 +0100 +++ b/gmyth-stream/server/0.3/lib/request_handler.py Tue Aug 21 16:02:24 2007 +0100 @@ -362,7 +362,8 @@ return #Only stream files on .transcode dir - filename = ".transcode/" + os.path.basename(filename) + filename = ".transcoded/" + os.path.basename(filename) + self.log.error("Stream file: %s" % filename) if not os.path.exists (filename): self.send_error(404, "File not found") return @@ -386,13 +387,16 @@ self.transcoders_log.insert(test_tid, "gms.Stream: %s" % filename) try: + file_data = "" while data_in != "": data_in = media.read(4096) - total_read += 4096 - self.wfile.write(data_in) - status = utils.progress_bar(total_read, size, 50) - msg_status = "Status:%s:%s%%" % (test_tid, status) - self.transcoders_log._update_status(test_tid, msg_status) + file_data += data_in + + #total_read += 4096 + self.wfile.write(file_data) + #status = utils.progress_bar(total_read, size, 50) + #msg_status = "Status:%s:%s%%" % (test_tid, status) + #self.transcoders_log._update_status(test_tid, msg_status) self.transcoders_log._update_status(test_tid, "OK: Done") @@ -435,7 +439,11 @@ obj.log = self.transcoders_log self.server.add_transcoders(self, obj) - obj.start(self.wfile) + if obj.start(self.wfile): + self.transcoders_log.info (test_tid, "OK") + else: + self.transcoders_log.info (test_tid, "Fail") + self.server.del_transcoders(self, obj) files.TranscodedFile("", self.query)