adshares / ads

ADS Blockchain
Other
21 stars 4 forks source link

set_account_status function accepted 64bit integer #55

Closed PawelPodkalicki closed 6 years ago

PawelPodkalicki commented 6 years ago

Call

(echo '{"run":"get_me"}';echo '{"run":"set_account_status", "address":"0001-00000000-9B6F", "status":"9223372036854775808"}')

was accepted

{
    "current_block_time": "1528208448",
    "previous_block_time": "1528208416",
    "tx": {
        "data": "0B0100000000003F0000005C9C165B01000000000000003C67C449E9353935723552A948D0B551724A53D4B02ABF0D2A21A1DB4C9A05D0D7BE95380FECA4C0C92259D590ABDDAF31DD2CD53D73C9EF24DBE0D6623F790C",
        "account_msid": "63",
        "account_hashin": "A05F5ECDC4F43233178EB2A4B93A58C4DACB447B44FA9A2B9457883204064184",
        "account_hashout": "C013D351A1AD6B31EF04682D7732FBD347D9D4D249E4038F892CDE2F114F68AF",
        "deduct": "0.00010000000",
        "fee": "0.00010000000",
        "node_msid": "4",
        "node_mpos": "55",
        "id": "0001:00000004:0037"
    },
    "account": {
        "address": "0001-00000000-9B6F",
        "node": "1",
        "id": "0",
        "msid": "64",
        "time": "1528208476",
        "date": "2018-06-05 16:21:16",
        "status": "65534",
        "paired_node": "1",
        "paired_id": "0",
        "local_change": "1528208448",
        "remote_change": "1528208416",
        "balance": "19999999.99379959602",
        "public_key": "A9C0D972D8AAB73805EC4A28291E052E3B5FAFE0ADC9D724917054E5E2690363",
        "hash": "C013D351A1AD6B31EF04682D7732FBD347D9D4D249E4038F892CDE2F114F68AF"
    }
}

Number 9223372036854775808 is 64 bit integer:

1000 0000 0000 0000 
0000 0000 0000 0000 
0000 0000 0000 0000 
0000 0000 0000 0000

According to wiki, status should be 16 bit integer. Fee was charged. Did this transaction impact node anyhow?

PawelPodkalicki commented 6 years ago

Fixed in 728a076f167db31e15681ca950b7ac1dd8ccd246 Client returns {"error":"Parse error, check input data"}