mirror of
https://github.com/aria2/aria2.git
synced 2026-04-02 10:55:00 +00:00
Return 400 status code if there is an error in RPC level
200 status code means success. Since the request did not succeed, we should avoid it.
This commit is contained in:
@@ -117,7 +117,7 @@ void HttpServerBodyCommand::sendJsonRpcResponse
|
||||
switch(res.code) {
|
||||
case 1:
|
||||
// error caught while executing RpcMethod
|
||||
httpCode = 200;
|
||||
httpCode = 400;
|
||||
break;
|
||||
case -32600:
|
||||
httpCode = 400;
|
||||
|
||||
Reference in New Issue
Block a user