Loading system/service/Android.mk +2 −2 Original line number Diff line number Diff line Loading @@ -25,9 +25,9 @@ btserviceCommonSrc := \ gatt_server.cpp \ hal/bluetooth_interface.cpp \ ipc/ipc_handler.cpp \ ipc/ipc_handler_unix.cpp \ ipc/ipc_manager.cpp \ ipc/unix_ipc_host.cpp \ ipc/unix/ipc_handler_unix.cpp \ ipc/unix/unix_ipc_host.cpp \ logging_helpers.cpp \ settings.cpp \ util/atomic_string.cpp \ Loading system/service/ipc/binder/ipc_handler_binder.cpp +2 −0 Original line number Diff line number Diff line Loading @@ -31,6 +31,7 @@ using android::status_t; using android::String16; namespace ipc { namespace binder { IPCHandlerBinder::IPCHandlerBinder( bluetooth::Adapter* adapter, Loading Loading @@ -79,4 +80,5 @@ void IPCHandlerBinder::NotifyStarted() { delegate()->OnIPCHandlerStarted(IPCManager::TYPE_BINDER); } } // namespace binder } // namespace ipc system/service/ipc/binder/ipc_handler_binder.h +2 −0 Original line number Diff line number Diff line Loading @@ -22,6 +22,7 @@ #include "service/ipc/ipc_manager.h" namespace ipc { namespace binder { // Implements a Binder based IPCHandler. class IPCHandlerBinder : public IPCHandler { Loading @@ -43,4 +44,5 @@ class IPCHandlerBinder : public IPCHandler { DISALLOW_COPY_AND_ASSIGN(IPCHandlerBinder); }; } // namespace binder } // namespace ipc system/service/ipc/ipc_manager.cpp +3 −3 Original line number Diff line number Diff line Loading @@ -17,7 +17,7 @@ #include "service/ipc/ipc_manager.h" #include "service/ipc/binder/ipc_handler_binder.h" #include "service/ipc/ipc_handler_unix.h" #include "service/ipc/unix/ipc_handler_unix.h" namespace ipc { Loading @@ -43,7 +43,7 @@ bool IPCManager::Start(Type type, Delegate* delegate) { return false; } unix_handler_ = new IPCHandlerUnix(adapter_, delegate); unix_handler_ = new unix::IPCHandlerUnix(adapter_, delegate); if (!unix_handler_->Run()) { unix_handler_ = nullptr; return false; Loading @@ -56,7 +56,7 @@ bool IPCManager::Start(Type type, Delegate* delegate) { return false; } binder_handler_ = new IPCHandlerBinder(adapter_, delegate); binder_handler_ = new binder::IPCHandlerBinder(adapter_, delegate); if (!binder_handler_->Run()) { binder_handler_ = nullptr; return false; Loading system/service/ipc/ipc_handler_unix.cpp→system/service/ipc/unix/ipc_handler_unix.cpp +4 −2 Original line number Diff line number Diff line Loading @@ -14,7 +14,7 @@ // limitations under the License. // #include "service/ipc/ipc_handler_unix.h" #include "service/ipc/unix/ipc_handler_unix.h" #include <sys/socket.h> #include <sys/un.h> Loading @@ -23,10 +23,11 @@ #include "osi/include/socket_utils/sockets.h" #include "service/daemon.h" #include "service/ipc/unix_ipc_host.h" #include "service/ipc/unix/unix_ipc_host.h" #include "service/settings.h" namespace ipc { namespace unix { IPCHandlerUnix::IPCHandlerUnix(bluetooth::Adapter* adapter, IPCManager::Delegate* delegate) Loading Loading @@ -212,4 +213,5 @@ void IPCHandlerUnix::NotifyStoppedOnCurrentThread() { delegate()->OnIPCHandlerStopped(IPCManager::TYPE_UNIX); } } // namespace unix } // namespace ipc Loading
system/service/Android.mk +2 −2 Original line number Diff line number Diff line Loading @@ -25,9 +25,9 @@ btserviceCommonSrc := \ gatt_server.cpp \ hal/bluetooth_interface.cpp \ ipc/ipc_handler.cpp \ ipc/ipc_handler_unix.cpp \ ipc/ipc_manager.cpp \ ipc/unix_ipc_host.cpp \ ipc/unix/ipc_handler_unix.cpp \ ipc/unix/unix_ipc_host.cpp \ logging_helpers.cpp \ settings.cpp \ util/atomic_string.cpp \ Loading
system/service/ipc/binder/ipc_handler_binder.cpp +2 −0 Original line number Diff line number Diff line Loading @@ -31,6 +31,7 @@ using android::status_t; using android::String16; namespace ipc { namespace binder { IPCHandlerBinder::IPCHandlerBinder( bluetooth::Adapter* adapter, Loading Loading @@ -79,4 +80,5 @@ void IPCHandlerBinder::NotifyStarted() { delegate()->OnIPCHandlerStarted(IPCManager::TYPE_BINDER); } } // namespace binder } // namespace ipc
system/service/ipc/binder/ipc_handler_binder.h +2 −0 Original line number Diff line number Diff line Loading @@ -22,6 +22,7 @@ #include "service/ipc/ipc_manager.h" namespace ipc { namespace binder { // Implements a Binder based IPCHandler. class IPCHandlerBinder : public IPCHandler { Loading @@ -43,4 +44,5 @@ class IPCHandlerBinder : public IPCHandler { DISALLOW_COPY_AND_ASSIGN(IPCHandlerBinder); }; } // namespace binder } // namespace ipc
system/service/ipc/ipc_manager.cpp +3 −3 Original line number Diff line number Diff line Loading @@ -17,7 +17,7 @@ #include "service/ipc/ipc_manager.h" #include "service/ipc/binder/ipc_handler_binder.h" #include "service/ipc/ipc_handler_unix.h" #include "service/ipc/unix/ipc_handler_unix.h" namespace ipc { Loading @@ -43,7 +43,7 @@ bool IPCManager::Start(Type type, Delegate* delegate) { return false; } unix_handler_ = new IPCHandlerUnix(adapter_, delegate); unix_handler_ = new unix::IPCHandlerUnix(adapter_, delegate); if (!unix_handler_->Run()) { unix_handler_ = nullptr; return false; Loading @@ -56,7 +56,7 @@ bool IPCManager::Start(Type type, Delegate* delegate) { return false; } binder_handler_ = new IPCHandlerBinder(adapter_, delegate); binder_handler_ = new binder::IPCHandlerBinder(adapter_, delegate); if (!binder_handler_->Run()) { binder_handler_ = nullptr; return false; Loading
system/service/ipc/ipc_handler_unix.cpp→system/service/ipc/unix/ipc_handler_unix.cpp +4 −2 Original line number Diff line number Diff line Loading @@ -14,7 +14,7 @@ // limitations under the License. // #include "service/ipc/ipc_handler_unix.h" #include "service/ipc/unix/ipc_handler_unix.h" #include <sys/socket.h> #include <sys/un.h> Loading @@ -23,10 +23,11 @@ #include "osi/include/socket_utils/sockets.h" #include "service/daemon.h" #include "service/ipc/unix_ipc_host.h" #include "service/ipc/unix/unix_ipc_host.h" #include "service/settings.h" namespace ipc { namespace unix { IPCHandlerUnix::IPCHandlerUnix(bluetooth::Adapter* adapter, IPCManager::Delegate* delegate) Loading Loading @@ -212,4 +213,5 @@ void IPCHandlerUnix::NotifyStoppedOnCurrentThread() { delegate()->OnIPCHandlerStopped(IPCManager::TYPE_UNIX); } } // namespace unix } // namespace ipc