IPC: External polling loop with a Client
[platform/core/security/vasum.git] / common / ipc / service.cpp
index be95cee..5e720d6 100644 (file)
@@ -91,15 +91,15 @@ std::vector<FileDescriptor> Service::getFDs()
 
 void Service::handle(const FileDescriptor fd, const short pollEvent)
 {
-    if (fd == mProcessor.getEventFD() && pollEvent & POLLIN) {
+    if (fd == mProcessor.getEventFD() && (pollEvent & POLLIN)) {
         mProcessor.handleEvent();
         return;
 
-    } else if (fd == mAcceptor.getConnectionFD() && pollEvent & POLLIN) {
+    } else if (fd == mAcceptor.getConnectionFD() && (pollEvent & POLLIN)) {
         mAcceptor.handleConnection();
         return;
 
-    } else if (fd == mAcceptor.getEventFD() && pollEvent & POLLIN) {
+    } else if (fd == mAcceptor.getEventFD() && (pollEvent & POLLIN)) {
         mAcceptor.handleEvent();
         return;