From 4d76449e7f45d125b8427e63e06d733ee73a84c4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=A6=8C=EA=A6=AB=EA=A6=B6=EA=A6=8F=EA=A7=80=EA=A6=A6?= =?UTF-8?q?=EA=A6=BF=EA=A6=A7=EA=A6=AE=EA=A6=91=EA=A6=A9=EA=A6=AD=EA=A7=80?= Date: Fri, 4 Jun 2021 14:32:25 +0800 Subject: Android configure wrappers --- request.h | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) (limited to 'request.h') diff --git a/request.h b/request.h index 1d15b6a..a943687 100644 --- a/request.h +++ b/request.h @@ -1,7 +1,7 @@ #ifndef ICCLIENT_REQUEST_H #define ICCLIENT_REQUEST_H -#if defined(ANDROID) && defined(DEBUG) +#if defined __ANDROID__ && defined DEBUG #include #endif #include @@ -77,19 +77,18 @@ inline void request(size_t (*writefunction)(void *, size_t, size_t, void *), #ifdef DEBUG CURLcode res = -#endif // DEBUG +#endif curl_easy_perform(curl); #ifdef DEBUG if (res != CURLE_OK) { const char *error = curl_easy_strerror(res); -#ifdef ANDROID - __android_log_print(ANDROID_LOG_ERROR, "libicclient", "%s: %s", __func__, - error); +#ifdef __ANDROID__ + __android_log_print(ANDROID_LOG_ERROR, "libicclient.so", "%s: %s", __func__, error); #else fprintf(stderr, "%s: %s\n", __func__, error); -#endif // ANDROID +#endif } -#endif // DEBUG +#endif } -#endif // ICCLIENT_REQUEST_H +#endif -- cgit v1.2.3