#include <sys/stat.h>
#include <ctype.h>
+extern void initialize_targets PARAMS ((void));
+
+extern void initialize_utils PARAMS ((void));
+
/* Prototypes for local functions */
static char * line_completion_function PARAMS ((char *, int, char *, int));
void (*call_command_hook) PARAMS ((struct cmd_list_element *c, char *cmd,
int from_tty));
-/* An alternate way to read memory for disassembly. This is used to provide a
- switch that allows disassembly to come from an exec file rather than a
- remote target. This is a speed hack. */
-
-int (*dis_asm_read_memory_hook) PARAMS ((bfd_vma memaddr, bfd_byte *myaddr,
- int len, disassemble_info *info));
/* Takes control from error (). Typically used to prevent longjmps out of the
middle of the GUI. Usually used in conjunction with a catch routine. */
locate_arg (p)
char *p;
{
- while (p = strchr (p, '$'))
+ while ((p = strchr (p, '$')))
{
if (strncmp (p, "$arg", 4) == 0 && isdigit (p[4]))
return p;
/* First we need to know how much memory to allocate for the new line. */
save_line = line;
len = 0;
- while (p = locate_arg (line))
+ while ((p = locate_arg (line)))
{
len += p - line;
i = p[4] - '0';
/* Save pointer to beginning of new line. */
save_line = new_line;
- while (p = locate_arg (line))
+ while ((p = locate_arg (line)))
{
int i, len;
new_line += p - line;
i = p[4] - '0';
- if (len = user_args->a[i].len)
+ len = user_args->a[i].len;
+ if (len)
{
memcpy (new_line, user_args->a[i].arg, len);
new_line += len;