adshares / ads

ADS Blockchain
Other
21 stars 4 forks source link

Node stops after incorrect send_many request #134

Closed PawelPodkalicki closed 6 years ago

PawelPodkalicki commented 6 years ago

During tests I call send many with one wire (correct address and empty amount).

(echo '{"run":"get_me"}';echo '{"run":"send_many", "wires":{"0001-00000000-XXXX":""}}') | ads -w .

Client accepted transfer and send it to network. Node stopped with error.

[1532939331] STOPing validation to finish msg list
[1532939331] STOPed validation to finish msg list
[1532939331] ____ HASH 0001:00000002 0001000000020352 DC5277B3FCC36FFFA19B4B89567CAAD81A5C30DCEBED5272E85C46D3101D8FE3
[1532939331] ____ HASH 0002:0000000A 00020000000A035A D45A3964D61A68A93EED1F815B99A7056DA8F04068B239CA45CA19467488F4FF
[1532939331] ____ HASH 0002:0000000B 00020000000B03C9 C2C95955B8FD1319AC929F735C9F439648C4F7A3DB6F6DE049EC6A90ECD324F0
[1532939331] ____ HASH 0002:0000000C 00020000000C0302 5802FC116D497DDEDE52BC6CCFEC736A0D1EB2A36CC74D61BF5EA5F1160196A8
[1532939331] REMOVE bad message 0001:00000003 [min:00000000 len:196]
[1532939331] ERROR: trying to remove own invalid message, FATAL, MUST RESUBMIT (TODO!)
[1532939331] 
SIGNAL: 3
PawelPodkalicki commented 6 years ago

Same for amount equal 0.

(echo '{"run":"get_me"}';echo '{"run":"send_many", "wires":{"0001-00000000-XXXX":"0"}}') | ads -w .
PawelPodkalicki commented 6 years ago

Fixed in d70d04c04637cc6ea8ba58c84d5a4c66bec82b49 Error Amount must be positive is returned.