don't insert unnecessary NUL byte in coinbase script when not merged mining
authorForrest Voight <forrest.voight@gmail.com>
Mon, 13 Aug 2012 21:55:14 +0000 (17:55 -0400)
committerForrest Voight <forrest.voight@gmail.com>
Tue, 14 Aug 2012 18:55:45 +0000 (14:55 -0400)
p2pool/work.py

index 5ba9025..8e9c6fa 100644 (file)
@@ -187,7 +187,7 @@ class WorkerBridge(worker_interface.WorkerBridge):
                     previous_share_hash=self.best_share_var.value,
                     coinbase=(script.create_push_script([
                         self.current_work.value['height'],
-                        mm_data,
+                        ] + ([mm_data] if mm_data else []) + [
                     ]) + self.current_work.value['coinbaseflags'])[:100],
                     nonce=random.randrange(2**32),
                     pubkey_hash=pubkey_hash,