diff mbox series

ctf-reader: Remove useless parameter from fill_ctf_section

Message ID 87zgpwtb47.fsf@redhat.com
State New
Headers show
Series ctf-reader: Remove useless parameter from fill_ctf_section | expand

Commit Message

Dodji Seketeli Nov. 22, 2021, 4:21 p.m. UTC
Hello,

While looking at something else, I noticed fill_ctf_section now has a
useless parameter that was making compiling with some "tight" options
cringe.

Fixed thus.

	* src/abg-ctf-reader.cc (fill_ctf_section): Remove the now useless
	context parameter.  Adjust the comment accordingly.
	(slurp_elf_info): Adjust the invocation of fill_ctf_section.

Signed-off-by: Dodji Seketeli <dodji@redhat.com>
---
 src/abg-ctf-reader.cc | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

Comments

Jose E. Marchesi Nov. 22, 2021, 6:23 p.m. UTC | #1
> Hello,
>
> While looking at something else, I noticed fill_ctf_section now has a
> useless parameter that was making compiling with some "tight" options
> cringe.
>
> Fixed thus.
>
> 	* src/abg-ctf-reader.cc (fill_ctf_section): Remove the now useless
> 	context parameter.  Adjust the comment accordingly.
> 	(slurp_elf_info): Adjust the invocation of fill_ctf_section.
>
> Signed-off-by: Dodji Seketeli <dodji@redhat.com>

Thanks.
diff mbox series

Patch

diff --git a/src/abg-ctf-reader.cc b/src/abg-ctf-reader.cc
index 2c2c204d..fd53f8a1 100644
--- a/src/abg-ctf-reader.cc
+++ b/src/abg-ctf-reader.cc
@@ -992,12 +992,11 @@  close_elf_handler (read_context *ctxt)
 /// Fill a CTF section description with the information in a given ELF
 /// section.
 ///
-/// @param ctxt the read context.
 /// @param elf_section the ELF section from which to get.
 /// @param ctf_section the CTF section to fill with the raw data.
 
 static void
-fill_ctf_section(read_context *ctxt, Elf_Scn *elf_section, ctf_sect_t *ctf_section)
+fill_ctf_section(Elf_Scn *elf_section, ctf_sect_t *ctf_section)
 {
   GElf_Shdr section_header_mem, *section_header;
   Elf_Data *section_data;
@@ -1046,9 +1045,9 @@  slurp_elf_info(read_context *ctxt, corpus_sptr corp)
   if (ctf_scn == NULL || symtab_scn == NULL || strtab_scn == NULL)
     return 0;
 
-  fill_ctf_section(ctxt, ctf_scn, &ctxt->ctf_sect);
-  fill_ctf_section(ctxt, symtab_scn, &ctxt->symtab_sect);
-  fill_ctf_section(ctxt, strtab_scn, &ctxt->strtab_sect);
+  fill_ctf_section(ctf_scn, &ctxt->ctf_sect);
+  fill_ctf_section(symtab_scn, &ctxt->symtab_sect);
+  fill_ctf_section(strtab_scn, &ctxt->strtab_sect);
 
   return 1;
 }