[PATCH] Two branches in a conditional structure should not have exactly the same implementation

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Signed-off-by: dinglimin <dinglimin@xxxxxxxxxxxxxxxxxxxx>
---
 scripts/apibuild.py | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/scripts/apibuild.py b/scripts/apibuild.py
index c232b4e2c8..5993318490 100755
--- a/scripts/apibuild.py
+++ b/scripts/apibuild.py
@@ -1248,10 +1248,8 @@ class CParser:
                                token[1] == "," or token[1] == "="):
                                 self.index_add_ref(oldtok[1], self.filename,
                                                    0, "type")
-                    elif oldtok[0] == "name" and oldtok[1][0:4] == "XEN_":
-                        self.index_add_ref(oldtok[1], self.filename,
-                                           0, "typedef")
-                    elif oldtok[0] == "name" and oldtok[1][0:7] == "LIBXEN_":
+                    elif oldtok[0] == "name" and (oldtok[1][0:4] == "XEN_" or
+                          oldtok[1][0:7] == "LIBXEN_"):
                         self.index_add_ref(oldtok[1], self.filename,
                                            0, "typedef")
 
-- 
2.30.0.windows.2






[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux