1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
$NetBSD: patch-ae,v 1.2 2005/02/19 15:40:54 wiz Exp $
--- disasm/badautil.c.orig 1999-08-31 18:19:14.000000000 +0200
+++ disasm/badautil.c
@@ -5,6 +5,7 @@
*/
#include <stdio.h>
+#include <stdlib.h>
#include <string.h>
#include <sys/stat.h> /* for stat */
#include <sys/types.h> /* for stat */
@@ -19,13 +20,6 @@
#include "../include/disutils.h"
-extern int fprintf(FILE*,const char*,...);
-extern int fputc(int , FILE*);
-extern int fputs(const char*,FILE*);
-extern int sscanf(const char*,const char*,...);
-extern int fclose(FILE*);
-extern void rewind(FILE*);
-
FNAME_STRING prog_name; /* to hold the name of the disassembler */
char pn_root[] =
@@ -213,13 +207,12 @@ void close_ifile(FILE* f,int* cur_ifile)
level--;
}
-char buf[BUFSIZE];
-
void show_line(FILE* f, int* cur_ifile)
/* write the source file line inputfile[*cur_ifile].line_no to */
/* file 'f', indicating the proper file include level. */
{
int i;
+ char buf[BUFSIZE];
for (i = 0; i< level; i++) fputc('>',f);
fgets(buf,BUFSIZE,inputfile[*cur_ifile].f);
|