1
0
mirror of https://github.com/unrealircd/unrealircd.git synced 2026-07-10 23:03:13 +02:00

JSON-RPC: Use proper error response with error codes according to

the official specification (one of JSON_RPC_ERROR_*).

Add proper rpc_error() and rpc_error_fmt()

Don't steal reference in rpc_response().
This commit is contained in:
Bram Matthys
2022-06-06 17:18:22 +02:00
parent 4cd520d327
commit 61ba3727df
6 changed files with 84 additions and 15 deletions
+1
View File
@@ -2481,6 +2481,7 @@ enum EfunctionType {
EFUNC_WEBSERVER_CLOSE_CLIENT,
EFUNC_RPC_RESPONSE,
EFUNC_RPC_ERROR,
EFUNC_RPC_ERROR_FMT,
};
/* Module flags */