summaryrefslogtreecommitdiff
path: root/rtclient.c
diff options
context:
space:
mode:
authorErik Prabowo Kamal <erik@darapsa.co.id>2019-09-03 16:22:28 +0800
committerErik Prabowo Kamal <erik@darapsa.co.id>2019-09-03 16:22:28 +0800
commit134ca7ec223e1d24b23ae6a8894d844baaf15c2b (patch)
tree86872b7e12edcfd00d61395a6fac197950c149af /rtclient.c
parent4f1ff2cfa54ee406067ffb4613feae852a5ea357 (diff)
Managed to get user properties
after having the cookie.
Diffstat (limited to 'rtclient.c')
-rw-r--r--rtclient.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/rtclient.c b/rtclient.c
index 59c80e6..cad4047 100644
--- a/rtclient.c
+++ b/rtclient.c
@@ -73,6 +73,12 @@ void rtclient_login(const char *name, const char *password)
#endif // ANDROID
}
#endif // DEBUG
+ 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);
+ curl_easy_setopt(handle, CURLOPT_URL, user_url);
+ curl_easy_setopt(handle, CURLOPT_HTTPGET, 1L);
+ curl_easy_perform(handle);
}
void rtclient_cleanup()