public inbox for libabigail@sourceware.org
 help / color / mirror / Atom feed
* [PATCH] abg-reader.cc: Fix code indentation and tabify.
@ 2020-03-28 19:54 Giuliano Procida
  2020-03-29 15:11 ` Matthias Maennich
  0 siblings, 1 reply; 3+ messages in thread
From: Giuliano Procida @ 2020-03-28 19:54 UTC (permalink / raw)
  To: libabigail; +Cc: dodji, kernel-team, gprocida

	* src/abg-reader.cc (build_elf_symbol_db): Fix code
	indentation.
	(build_array_type_def): Tabify.

Signed-off-by: Giuliano Procida <gprocida@google.com>
---
 src/abg-reader.cc | 50 +++++++++++++++++++++++------------------------
 1 file changed, 25 insertions(+), 25 deletions(-)

diff --git a/src/abg-reader.cc b/src/abg-reader.cc
index 019c0e99..340223d0 100644
--- a/src/abg-reader.cc
+++ b/src/abg-reader.cc
@@ -3005,24 +3005,24 @@ build_elf_symbol_db(read_context& ctxt,
     {
       if (xml_char_sptr s = XML_NODE_GET_ATTRIBUTE(x->first, "alias"))
 	{
-      string alias_id = CHAR_STR(s);
-
-      // Symbol aliases can be multiple separated by comma(,), split them
-      std::vector<std::string> elems;
-      std::stringstream aliases(alias_id);
-      std::string item;
-      while (std::getline(aliases, item, ','))
-        elems.push_back(item);
-      for (std::vector<string>::iterator alias = elems.begin();
-           alias != elems.end(); ++alias)
-        {
-          string_elf_symbol_sptr_map_type::const_iterator i =
-          id_sym_map.find(*alias);
-          ABG_ASSERT(i != id_sym_map.end());
-          ABG_ASSERT(i->second->is_main_symbol());
-
-          x->second->get_main_symbol()->add_alias(i->second);
-        }
+	  string alias_id = CHAR_STR(s);
+
+	  // Symbol aliases can be multiple separated by comma(,), split them
+	  std::vector<std::string> elems;
+	  std::stringstream aliases(alias_id);
+	  std::string item;
+	  while (std::getline(aliases, item, ','))
+	    elems.push_back(item);
+	  for (std::vector<string>::iterator alias = elems.begin();
+	       alias != elems.end(); ++alias)
+	    {
+	      string_elf_symbol_sptr_map_type::const_iterator i =
+	      id_sym_map.find(*alias);
+	      ABG_ASSERT(i != id_sym_map.end());
+	      ABG_ASSERT(i->second->is_main_symbol());
+
+	      x->second->get_main_symbol()->add_alias(i->second);
+	    }
 	}
     }
 
@@ -4021,12 +4021,12 @@ build_array_type_def(read_context&	ctxt,
     {
       size_in_bits = strtoull(CHAR_STR(s), &endptr, 0);
       if (*endptr != '\0')
-        {
-          if (!strcmp(CHAR_STR(s), "infinite"))
-            size_in_bits = (size_t) -1;
-          else
-            return nil;
-        }
+	{
+	  if (!strcmp(CHAR_STR(s), "infinite"))
+	    size_in_bits = (size_t) -1;
+	  else
+	    return nil;
+	}
       has_size_in_bits = true;
     }
 
@@ -4034,7 +4034,7 @@ build_array_type_def(read_context&	ctxt,
     {
       alignment_in_bits = strtoull(CHAR_STR(s), &endptr, 0);
       if (*endptr != '\0')
-        return nil;
+	return nil;
     }
 
   string id;
-- 
2.26.0.rc2.310.g2932bb562d-goog


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] abg-reader.cc: Fix code indentation and tabify.
  2020-03-28 19:54 [PATCH] abg-reader.cc: Fix code indentation and tabify Giuliano Procida
@ 2020-03-29 15:11 ` Matthias Maennich
  2020-03-30  9:53   ` Dodji Seketeli
  0 siblings, 1 reply; 3+ messages in thread
From: Matthias Maennich @ 2020-03-29 15:11 UTC (permalink / raw)
  To: Giuliano Procida; +Cc: libabigail, dodji, kernel-team

On Sat, Mar 28, 2020 at 07:54:34PM +0000, Android Kernel Team wrote:
>	* src/abg-reader.cc (build_elf_symbol_db): Fix code
>	indentation.
>	(build_array_type_def): Tabify.
>
>Signed-off-by: Giuliano Procida <gprocida@google.com>

Reviewed-by: Matthias Maennich <maennich@google.com>

Cheers,
Matthias

>---
> src/abg-reader.cc | 50 +++++++++++++++++++++++------------------------
> 1 file changed, 25 insertions(+), 25 deletions(-)
>
>diff --git a/src/abg-reader.cc b/src/abg-reader.cc
>index 019c0e99..340223d0 100644
>--- a/src/abg-reader.cc
>+++ b/src/abg-reader.cc
>@@ -3005,24 +3005,24 @@ build_elf_symbol_db(read_context& ctxt,
>     {
>       if (xml_char_sptr s = XML_NODE_GET_ATTRIBUTE(x->first, "alias"))
> 	{
>-      string alias_id = CHAR_STR(s);
>-
>-      // Symbol aliases can be multiple separated by comma(,), split them
>-      std::vector<std::string> elems;
>-      std::stringstream aliases(alias_id);
>-      std::string item;
>-      while (std::getline(aliases, item, ','))
>-        elems.push_back(item);
>-      for (std::vector<string>::iterator alias = elems.begin();
>-           alias != elems.end(); ++alias)
>-        {
>-          string_elf_symbol_sptr_map_type::const_iterator i =
>-          id_sym_map.find(*alias);
>-          ABG_ASSERT(i != id_sym_map.end());
>-          ABG_ASSERT(i->second->is_main_symbol());
>-
>-          x->second->get_main_symbol()->add_alias(i->second);
>-        }
>+	  string alias_id = CHAR_STR(s);
>+
>+	  // Symbol aliases can be multiple separated by comma(,), split them
>+	  std::vector<std::string> elems;
>+	  std::stringstream aliases(alias_id);
>+	  std::string item;
>+	  while (std::getline(aliases, item, ','))
>+	    elems.push_back(item);
>+	  for (std::vector<string>::iterator alias = elems.begin();
>+	       alias != elems.end(); ++alias)
>+	    {
>+	      string_elf_symbol_sptr_map_type::const_iterator i =
>+	      id_sym_map.find(*alias);
>+	      ABG_ASSERT(i != id_sym_map.end());
>+	      ABG_ASSERT(i->second->is_main_symbol());
>+
>+	      x->second->get_main_symbol()->add_alias(i->second);
>+	    }
> 	}
>     }
>
>@@ -4021,12 +4021,12 @@ build_array_type_def(read_context&	ctxt,
>     {
>       size_in_bits = strtoull(CHAR_STR(s), &endptr, 0);
>       if (*endptr != '\0')
>-        {
>-          if (!strcmp(CHAR_STR(s), "infinite"))
>-            size_in_bits = (size_t) -1;
>-          else
>-            return nil;
>-        }
>+	{
>+	  if (!strcmp(CHAR_STR(s), "infinite"))
>+	    size_in_bits = (size_t) -1;
>+	  else
>+	    return nil;
>+	}
>       has_size_in_bits = true;
>     }
>
>@@ -4034,7 +4034,7 @@ build_array_type_def(read_context&	ctxt,
>     {
>       alignment_in_bits = strtoull(CHAR_STR(s), &endptr, 0);
>       if (*endptr != '\0')
>-        return nil;
>+	return nil;
>     }
>
>   string id;
>-- 
>2.26.0.rc2.310.g2932bb562d-goog
>
>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] abg-reader.cc: Fix code indentation and tabify.
  2020-03-29 15:11 ` Matthias Maennich
@ 2020-03-30  9:53   ` Dodji Seketeli
  0 siblings, 0 replies; 3+ messages in thread
From: Dodji Seketeli @ 2020-03-30  9:53 UTC (permalink / raw)
  To: Matthias Maennich; +Cc: Giuliano Procida, libabigail, kernel-team

Matthias Maennich <maennich@google.com> a écrit:

> On Sat, Mar 28, 2020 at 07:54:34PM +0000, Android Kernel Team wrote:
>>	* src/abg-reader.cc (build_elf_symbol_db): Fix code
>>	indentation.
>>	(build_array_type_def): Tabify.
>>
>>Signed-off-by: Giuliano Procida <gprocida@google.com>
>
> Reviewed-by: Matthias Maennich <maennich@google.com>

Applied to master.

Thanks!

-- 
		Dodji

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-03-30  9:53 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-28 19:54 [PATCH] abg-reader.cc: Fix code indentation and tabify Giuliano Procida
2020-03-29 15:11 ` Matthias Maennich
2020-03-30  9:53   ` Dodji Seketeli

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).