liblog: convert to C++
Bug: 119867234
Test: liblog, logcat, logd unit tests
Change-Id: I2a33b6fc37f9860c0041e3573bfb59ea389f623c
diff --git a/liblog/logger.h b/liblog/logger.h
index af83228..7bb9b20 100644
--- a/liblog/logger.h
+++ b/liblog/logger.h
@@ -29,7 +29,7 @@
__BEGIN_DECLS
/* Union, sock or fd of zero is not allowed unless static initialized */
-union android_log_context {
+union android_log_context_union {
void* priv;
atomic_int sock;
atomic_int fd;
@@ -41,7 +41,7 @@
struct listnode node;
const char* name; /* human name to describe the transport */
unsigned logMask; /* mask cache of available() success */
- union android_log_context context; /* Initialized by static allocation */
+ union android_log_context_union context; /* Initialized by static allocation */
int (*available)(log_id_t logId); /* Does not cause resources to be taken */
int (*open)(); /* can be called multiple times, reusing current resources */
@@ -115,7 +115,7 @@
struct android_log_transport_context {
struct listnode node;
- union android_log_context context; /* zero init per-transport context */
+ union android_log_context_union context; /* zero init per-transport context */
struct android_log_logger_list* parent;
struct android_log_transport_read* transport;
@@ -161,7 +161,7 @@
LIBLOG_HIDDEN int __android_log_trylock();
LIBLOG_HIDDEN void __android_log_unlock();
-LIBLOG_HIDDEN int __android_log_transport;
+extern LIBLOG_HIDDEN int __android_log_transport;
__END_DECLS