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

[Xen-devel] [PATCH 07/20] create-diff-object: Add is_special_section() helper function



This function determines, based on the given section name, if the
sections belongs to the special sections category.

Signed-off-by: Pawel Wieczorkiewicz <wipawel@xxxxxxxxx>
Reviewed-by: Andra-Irina Paraschiv <andraprs@xxxxxxxxxx>
Reviewed-by: Bjoern Doebel <doebel@xxxxxxxxx>
Reviewed-by: Norbert Manthey <nmanthey@xxxxxxxxx>
Reviewed-by: Ross Lagerwall <ross.lagerwall@xxxxxxxxxx>
---
 create-diff-object.c | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/create-diff-object.c b/create-diff-object.c
index 4699ba0..0df3fea 100644
--- a/create-diff-object.c
+++ b/create-diff-object.c
@@ -1045,6 +1045,18 @@ static struct special_section special_sections[] = {
        {},
 };
 
+static int is_special_section(const struct section *sec)
+{
+       struct special_section *special;
+
+       for (special = special_sections; special->name; special++) {
+               if (!strcmp(sec->name, special->name))
+                       return true;
+       }
+
+       return false;
+}
+
 static int should_keep_rela_group(struct section *sec, int start, int size)
 {
        struct rela *rela;
-- 
2.16.5




Amazon Development Center Germany GmbH
Krausenstr. 38
10117 Berlin
Geschaeftsfuehrung: Christian Schlaeger, Ralf Herbrich
Eingetragen am Amtsgericht Charlottenburg unter HRB 149173 B
Sitz: Berlin
Ust-ID: DE 289 237 879




_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.