1 /* Initialize "struct disassemble_info".
3 Copyright 2003 Free Software Foundation, Inc.
5 This program is free software; you can redistribute it and/or
6 modify it under the terms of the GNU General Public License as
7 published by the Free Software Foundation; either version 2 of the
8 License, or (at your option) any later version.
10 This program is distributed in the hope that it will be useful, but
11 WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with this program; if not, write to the Free Software
17 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
25 init_disassemble_info (struct disassemble_info *info, void *stream,
26 fprintf_ftype fprintf_func)
28 memset (info, 0, sizeof (*info));
29 info->flavour = bfd_target_unknown_flavour;
30 info->arch = bfd_arch_unknown;
31 info->endian = BFD_ENDIAN_UNKNOWN;
32 info->octets_per_byte = 1;
33 info->fprintf_func = fprintf_func;
34 info->stream = stream;
35 info->read_memory_func = buffer_read_memory;
36 info->memory_error_func = perror_memory;
37 info->print_address_func = generic_print_address;
38 info->symbol_at_address_func = generic_symbol_at_address;
39 info->display_endian = BFD_ENDIAN_UNKNOWN;