From ed0d6e131fd94f4ed151df12834feffa777db840 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=A6=8C=20=EA=A6=AB=EA=A6=B6=20=EA=A6=8F=EA=A7=80?= =?UTF-8?q?=EA=A6=A6=EA=A6=BF=20=EA=A6=A7=20=EA=A6=AE=20=EA=A6=91=20?= =?UTF-8?q?=EA=A6=A9=20=EA=A6=AD=EA=A7=80?= Date: Wed, 4 Sep 2019 15:23:46 +0800 Subject: Separated the user properties retrieval function --- rtclient.c | 7 +++++++ rtclient.h | 1 + 2 files changed, 8 insertions(+) diff --git a/rtclient.c b/rtclient.c index 306aadc..4f42463 100644 --- a/rtclient.c +++ b/rtclient.c @@ -60,6 +60,13 @@ void rtclient_login(const char *name, const char *password) #endif // ANDROID } #endif // DEBUG +} + +void rtclient_user(const char *name) +{ +#ifdef DEBUG + fprintf(stderr, "NAME:\n%s\n", name); +#endif static const char *user_path = "/REST/1.0/user/"; char user_url[strlen(server_url) + strlen(user_path) + strlen(name) + 1]; sprintf(user_url, "%s%s%s", server_url, user_path, name); diff --git a/rtclient.h b/rtclient.h index 228c141..50a44c7 100644 --- a/rtclient.h +++ b/rtclient.h @@ -7,6 +7,7 @@ extern "C" { bool rtclient_init(const char *server_url); void rtclient_login(const char *name, const char *password); + void rtclient_user(const char *name); void rtclient_cleanup(); #ifdef __cplusplus -- cgit v1.2.3