Merge "Fix coveriy issue (Assert when fd = 0)" into devel/master
authorAdeel Kazmi <adeel.kazmi@samsung.com>
Fri, 29 Jul 2022 17:43:11 +0000 (17:43 +0000)
committerGerrit Code Review <gerrit@review>
Fri, 29 Jul 2022 17:43:11 +0000 (17:43 +0000)
dali/internal/system/linux/file-descriptor-monitor-ecore.cpp

index 35eb5c0..f121abe 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2021 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2022 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -105,7 +105,7 @@ FileDescriptorMonitor::FileDescriptorMonitor(int fileDescriptor, CallbackBase* c
 {
   mImpl = new Impl(fileDescriptor, callback, eventBitmask);
 
-  if(fileDescriptor < 1)
+  if(fileDescriptor < 0)
   {
     DALI_ASSERT_ALWAYS(0 && "Invalid File descriptor");
     return;