java/String: remove unnecessary env parameter

This commit is contained in:
Max Kellermann
2021-03-28 13:33:07 +02:00
committed by Max Kellermann
parent ee86434a89
commit 285ba54fe5

View File

@@ -66,9 +66,8 @@ public:
* @return a pointer to the terminating null byte, * @return a pointer to the terminating null byte,
* nullptr on error * nullptr on error
*/ */
char *CopyTo(JNIEnv *env, char *CopyTo(char *buffer, size_t max_size) const noexcept {
char *buffer, size_t max_size) const noexcept { return CopyTo(GetEnv(), Get(), buffer, max_size);
return CopyTo(env, Get(), buffer, max_size);
} }
static std::string ToString(JNIEnv *env, jstring s) noexcept; static std::string ToString(JNIEnv *env, jstring s) noexcept;