mirror of
https://github.com/haiwen/seafile.git
synced 2025-01-08 11:57:44 +08:00
add sync_error_id_to_str rpc
This commit is contained in:
parent
0abf6b8528
commit
e59f55b5f4
@ -16,7 +16,7 @@
|
||||
#include "common/mq-mgr.h"
|
||||
#include "seafile-config.h"
|
||||
#include "seafile-object.h"
|
||||
|
||||
#include "seafile-error-impl.h"
|
||||
#define DEBUG_FLAG SEAFILE_DEBUG_OTHER
|
||||
#include "log.h"
|
||||
|
||||
@ -1047,3 +1047,9 @@ seafile_shutdown (GError **error)
|
||||
exit(0);
|
||||
return 0;
|
||||
}
|
||||
|
||||
char*
|
||||
seafile_sync_error_id_to_str (int error_id, GError **error)
|
||||
{
|
||||
return g_strdup(sync_error_id_to_str (error_id));
|
||||
}
|
||||
|
@ -79,6 +79,11 @@ register_rpc_service ()
|
||||
searpc_create_service ("seafile-threaded-rpcserver");
|
||||
|
||||
/* seafile-rpcserver */
|
||||
searpc_server_register_function ("seafile-rpcserver",
|
||||
seafile_sync_error_id_to_str,
|
||||
"seafile_sync_error_id_to_str",
|
||||
searpc_signature_string__int());
|
||||
|
||||
searpc_server_register_function ("seafile-rpcserver",
|
||||
seafile_get_session_info,
|
||||
"seafile_get_session_info",
|
||||
|
@ -231,4 +231,7 @@ json_t * seafile_get_sync_notification (GError **error);
|
||||
|
||||
int
|
||||
seafile_shutdown (GError **error);
|
||||
|
||||
char*
|
||||
seafile_sync_error_id_to_str (int error_id, GError **error);
|
||||
#endif
|
||||
|
@ -13,6 +13,11 @@ class SeafileRpcClient(NamedPipeClient):
|
||||
**kwargs
|
||||
)
|
||||
|
||||
@searpc_func("string", ["int"])
|
||||
def seafile_sync_error_id_to_str():
|
||||
pass
|
||||
sync_error_id_to_str = seafile_sync_error_id_to_str
|
||||
|
||||
@searpc_func("object", [])
|
||||
def seafile_get_session_info():
|
||||
pass
|
||||
|
Loading…
Reference in New Issue
Block a user