1*3d8817e4Smiod /* Initialize "struct disassemble_info".
2*3d8817e4Smiod
3*3d8817e4Smiod Copyright 2003 Free Software Foundation, Inc.
4*3d8817e4Smiod
5*3d8817e4Smiod This program is free software; you can redistribute it and/or
6*3d8817e4Smiod modify it under the terms of the GNU General Public License as
7*3d8817e4Smiod published by the Free Software Foundation; either version 2 of the
8*3d8817e4Smiod License, or (at your option) any later version.
9*3d8817e4Smiod
10*3d8817e4Smiod This program is distributed in the hope that it will be useful, but
11*3d8817e4Smiod WITHOUT ANY WARRANTY; without even the implied warranty of
12*3d8817e4Smiod MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13*3d8817e4Smiod General Public License for more details.
14*3d8817e4Smiod
15*3d8817e4Smiod You should have received a copy of the GNU General Public License
16*3d8817e4Smiod along with this program; if not, write to the Free Software
17*3d8817e4Smiod Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
18*3d8817e4Smiod 02110-1301, USA. */
19*3d8817e4Smiod
20*3d8817e4Smiod #include "sysdep.h"
21*3d8817e4Smiod #include "dis-asm.h"
22*3d8817e4Smiod #include "bfd.h"
23*3d8817e4Smiod
24*3d8817e4Smiod void
init_disassemble_info(struct disassemble_info * info,void * stream,fprintf_ftype fprintf_func)25*3d8817e4Smiod init_disassemble_info (struct disassemble_info *info, void *stream,
26*3d8817e4Smiod fprintf_ftype fprintf_func)
27*3d8817e4Smiod {
28*3d8817e4Smiod memset (info, 0, sizeof (*info));
29*3d8817e4Smiod
30*3d8817e4Smiod info->flavour = bfd_target_unknown_flavour;
31*3d8817e4Smiod info->arch = bfd_arch_unknown;
32*3d8817e4Smiod info->endian = BFD_ENDIAN_UNKNOWN;
33*3d8817e4Smiod info->octets_per_byte = 1;
34*3d8817e4Smiod info->fprintf_func = fprintf_func;
35*3d8817e4Smiod info->stream = stream;
36*3d8817e4Smiod info->read_memory_func = buffer_read_memory;
37*3d8817e4Smiod info->memory_error_func = perror_memory;
38*3d8817e4Smiod info->print_address_func = generic_print_address;
39*3d8817e4Smiod info->symbol_at_address_func = generic_symbol_at_address;
40*3d8817e4Smiod info->symbol_is_valid = generic_symbol_is_valid;
41*3d8817e4Smiod info->display_endian = BFD_ENDIAN_UNKNOWN;
42*3d8817e4Smiod }
43*3d8817e4Smiod
44