git://git.novaco.in
/
p2pool.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
(parent:
7deaef0
)
added support for luke-jr's "Bugfix: getmemorypool 'bits' should be a hex-string"
author
Forrest Voight
<forrest@forre.st>
Mon, 10 Oct 2011 05:51:30 +0000 (
01:51
-0400)
committer
Forrest Voight
<forrest@forre.st>
Mon, 10 Oct 2011 05:51:30 +0000 (
01:51
-0400)
p2pool/main.py
patch
|
blob
|
history
diff --git
a/p2pool/main.py
b/p2pool/main.py
index
a2f10f7
..
0243baa
100644
(file)
--- a/
p2pool/main.py
+++ b/
p2pool/main.py
@@
-37,7
+37,7
@@
def getwork(bitcoind, ht, net):
transactions=[bitcoin.data.tx_type.unpack(x.decode('hex')) for x in work['transactions']],
subsidy=work['coinbasevalue'],
time=work['time'],
- target=bitcoin.data.FloatingInteger(work['bits']),
+ target=bitcoin.data.FloatingIntegerType().unpack(work['bits'].decode('hex')[::-1]) if isinstance(work['bits'], (str, unicode)) else bitcoin.data.FloatingInteger(work['bits']),
))
except jsonrpc.Error, e:
if e.code != -32601: