shithub: scc

Download patch

ref: 7d7f9350f29929ee02922b61e0950ab05d4d49eb
parent: 6b341367541d0a5a221fcb8cba6d6ff0a2d48e16
author: Roberto E. Vargas Caballero <[email protected]>
date: Tue Mar 6 07:38:08 EST 2018

[nm] Remove fname from object() parameters

--- a/nm/main.c
+++ b/nm/main.c
@@ -87,7 +87,7 @@
 		pos += siz;
 
 		getfname(&hdr, member);
-		if (object(fname, fp)) {
+		if (object(fp)) {
 			nm(fname, hdr.ar_name, fp);
 		} else {
 			fprintf(stderr,
@@ -154,7 +154,7 @@
 		exit(1);
 	}
 
-	if (object(fname, fp))
+	if (object(fp))
 		nm(fname, fname, fp);
 	else if (archive(fname, fp))
 		ar(fname, fp);
--- a/nm/myro.c
+++ b/nm/myro.c
@@ -125,7 +125,7 @@
 }
 
 int
-object(char *fname, FILE *fp)
+object(FILE *fp)
 {
 	char magic[MYROMAGIC_SIZ];
 	fpos_t pos;
--- a/nm/nm.h
+++ b/nm/nm.h
@@ -11,7 +11,7 @@
 
 /* object format file */
 extern void nm(char *fname, char *member, FILE *fp);
-extern int object(char *fname, FILE *fp);
+extern int object(FILE *fp);
 
 extern int radix;
 extern int Pflag;