~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to tests/resolve_stack_dump.cc

  • Committer: Monty Taylor
  • Date: 2009-03-04 02:16:28 UTC
  • mto: (917.1.2 mordred)
  • mto: This revision was merged to the branch mainline in revision 912.
  • Revision ID: mordred@inaugust.com-20090304021628-rfq0b16uoi09g8tx
Fix to make VPATH builds work again.

Show diffs side-by-side

added added

removed removed

Lines of Context:
21
21
#include <mystrings/m_ctype.h>
22
22
#include <mysys/my_sys.h>
23
23
#include <mystrings/m_string.h>
24
 
#include <drizzled/version.h>
25
24
#include <errno.h>
26
25
#include <mysys/my_getopt.h>
 
26
#include <stdio.h>
27
27
 
28
28
#define INIT_SYM_TABLE  4096
29
29
#define INC_SYM_TABLE  4096
41
41
 
42
42
static char* dump_fname = 0, *sym_fname = 0;
43
43
static DYNAMIC_ARRAY sym_table; /* how do you like this , static DYNAMIC ? */
44
 
static FILE* fp_dump, *fp_sym = 0, *fp_out; 
 
44
static FILE* fp_dump, *fp_sym = 0, *fp_out;
45
45
 
46
46
static struct my_option my_long_options[] =
47
47
{
63
63
static void print_version(void)
64
64
{
65
65
  printf("%s  Ver %s Distrib %s, for %s (%s)\n",my_progname,DUMP_VERSION,
66
 
         DRIZZLE_SERVER_VERSION,SYSTEM_TYPE,MACHINE_TYPE);
 
66
         VERSION,SYSTEM_TYPE,MACHINE_TYPE);
67
67
}
68
68
 
69
69
 
95
95
}
96
96
 
97
97
 
98
 
static bool
99
 
get_one_option(int optid, const struct my_option *opt __attribute__((unused)),
100
 
               char *argument __attribute__((unused)))
 
98
extern "C"
 
99
bool get_one_option(int optid, const struct my_option *, char *)
101
100
{
102
101
  switch(optid) {
103
102
  case 'V':
173
172
    return c - '0';
174
173
  l = my_tolower(&my_charset_utf8_general_ci,c);
175
174
  if (l < 'a' || l > 'f')
176
 
    return HEX_INVALID; 
 
175
    return HEX_INVALID;
177
176
  return (unsigned char)10 + ((unsigned char)c - (unsigned char)'a');
178
177
}
179
178
 
186
185
  while((c = hex_val(*p++)) != HEX_INVALID)
187
186
      addr = (addr << 4) + c;
188
187
 
189
 
  *buf = p; 
 
188
  *buf = p;
190
189
  return addr;
191
190
}
192
191