adshares / ads

ADS Blockchain
Other
21 stars 4 forks source link

Empty command returns "Unknown error occured" #145

Closed PawelPodkalicki closed 5 years ago

PawelPodkalicki commented 6 years ago

I run ads client and pressed [ENTER] to execute empty (invalid, non-json) command. The unknown error occured and client closed.

[1534411048] GOT REQUEST 
[1534411048] Main Exception: basic_string::at: __n (which is 0) >= this->size() (which is 0)
{
    "error": "Unknown error occured"
}

Empty command could be recognized.

PawelPodkalicki commented 6 years ago

When json command is not properly formatted, error "Parse error, check input data" is returned by default.