char buf[PBUFSIZ]; int nvals;
struct remote_state *rs = get_remote_state (); char *buf = alloca (rs->remote_packet_size); char *ptr; int lose;
get_offsets (){  char buf[PBUFSIZ];  int nvals;  CORE_ADDR text_addr, data_addr, bss_addr;  struct section_offsets *offs;  putpkt ("qOffsets");  getpkt (buf, 0);  if (buf[0] == '\000')    return;			/* Return silently.  Stub doesn't support this				   command. */  if (buf[0] == 'E')    {      warning ("Remote failure reply: %s", buf);      return;    }  nvals = sscanf (buf, "Text=%lx;Data=%lx;Bss=%lx", &text_addr, &data_addr,		  &bss_addr);  if (nvals != 3)    error ("Malformed response to offset query, %s", buf);  if (symfile_objfile == NULL)    return;  offs = (struct section_offsets *) alloca (sizeof (struct section_offsets)					    + symfile_objfile->num_sections					    * sizeof (offs->offsets));  memcpy (offs, symfile_objfile->section_offsets,	  sizeof (struct section_offsets)	  + symfile_objfile->num_sections	  * sizeof (offs->offsets));  ANOFFSET (offs, SECT_OFF_TEXT) = text_addr;  /* This is a temporary kludge to force data and bss to use the same offsets     because that's what nlmconv does now.  The real solution requires changes     to the stub and remote.c that I don't have time to do right now.  */  ANOFFSET (offs, SECT_OFF_DATA) = data_addr;  ANOFFSET (offs, SECT_OFF_BSS) = data_addr;  objfile_relocate (symfile_objfile, offs);}