Skip to content

Commit 7a8e75c

Browse files
committedAug 20, 2021
elfcreator: elfcreator_copy_scn() doesn't need the 'elf' arg
Not used at all, remove it. Cc: Peter Jones <pjones@redhat.com> Fixes: 29ef465 ("Add scncopy - like object copy but tries not to change section content") Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
1 parent 3925a5b commit 7a8e75c

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed
 

‎elfcreator.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ static void update_dyn_cache(ElfCreator *ctor)
108108
ctor->dyndata = elf_getdata(ctor->dynscn, NULL);
109109
}
110110

111-
void elfcreator_copy_scn(ElfCreator *ctor, Elf *src, Elf_Scn *scn)
111+
void elfcreator_copy_scn(ElfCreator *ctor, Elf_Scn *scn)
112112
{
113113
Elf_Scn *newscn;
114114
Elf_Data *indata, *outdata;

‎elfcreator.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
typedef struct elf_creator ElfCreator;
1414
extern ElfCreator *elfcreator_begin(char *path, Elf *elf);
15-
extern void elfcreator_copy_scn(ElfCreator *ctor, Elf *src, Elf_Scn *scn);
15+
extern void elfcreator_copy_scn(ElfCreator *ctor, Elf_Scn *scn);
1616
extern void elfcreator_end(ElfCreator *ctor);
1717

1818
#endif /* ELFCREATOR_H */

‎scncopy.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ int main(int argc, char *argv[])
118118
if (!should_copy_scn(elf, shdr, sections) && !copy_all_sections)
119119
continue;
120120

121-
elfcreator_copy_scn(ctor, elf, scn);
121+
elfcreator_copy_scn(ctor, scn);
122122
}
123123
elfcreator_end(ctor);
124124
return 0;

0 commit comments

Comments
 (0)
Please sign in to comment.