Retire convenience macros from JNIHelp.h
Retire macros that are multiply defined in the Android source tree and
not obviously part of JNIHelp.h interfaces:
- DISALLOW_COPY_AND_ASSIGN (consumers of the definition here, but with
alternatives).
- TEMP_FAILURE_RETRY (no consumers of the definition here)
Bug: 122995834
Test: m, device boots
Change-Id: I2c806a7741b648075fdffbeff6e2fe1765e9c0c2
diff --git a/include/nativehelper/JNIHelp.h b/include/nativehelper/JNIHelp.h
index bab5dd5..92a3882 100644
--- a/include/nativehelper/JNIHelp.h
+++ b/include/nativehelper/JNIHelp.h
@@ -272,29 +272,6 @@
jniLogException(&env->functions, priority, tag, exception);
}
-#if !defined(DISALLOW_COPY_AND_ASSIGN)
-// DISALLOW_COPY_AND_ASSIGN disallows the copy and operator= functions. It goes in the private:
-// declarations in a class.
-#define DISALLOW_COPY_AND_ASSIGN(TypeName) \
- TypeName(const TypeName&) = delete; \
- void operator=(const TypeName&) = delete
-#endif // !defined(DISALLOW_COPY_AND_ASSIGN)
-
#endif // defined(__cplusplus)
-/*
- * TEMP_FAILURE_RETRY is defined by some, but not all, versions of
- * <unistd.h>. (Alas, it is not as standard as we'd hoped!) So, if it's
- * not already defined, then define it here.
- */
-#ifndef TEMP_FAILURE_RETRY
-/* Used to retry syscalls that can return EINTR. */
-#define TEMP_FAILURE_RETRY(exp) ({ \
- typeof (exp) _rc; \
- do { \
- _rc = (exp); \
- } while (_rc == -1 && errno == EINTR); \
- _rc; })
-#endif
-
#endif /* NATIVEHELPER_JNIHELP_H_ */