Re: {CIRCLE][ASCII] same 8 character problems with a twist

From: John Hines (jahweb@grnco.net)
Date: 06/17/99


A bit of an update:
Program received signal SIGSEGV, Segmentation fault.
0x806ca7b in game_loop (mother_desc=0) at comm.c:859
859             GET_WAIT_STATE(d->character) -= (GET_WAIT_STATE(d->character) >
0);
(gdb) print d
$1 = (struct descriptor_data *) 0x83c7668
(gdb) print d->character
$2 = (char_data *) 0x83c9928
(gdb) print *d
$3 = {descriptor = 6, host = "ppp209.grnco.net", '\000' <repeats 14 times>,
  bad_pws = 0 '\000', idle_tics = 0 '\000', connected = 0, desc_num = 1,
  login_time = 929603798, showstr_head = 0x0, showstr_vector = 0x83ccc70,
  showstr_count = 0, showstr_page = 0, str = 0x0, max_str = 0, backstr = 0x0,
  mail_to = 0, has_prompt = 1,
  inbuf = "\000 the reconnect\n\000ly\n\000n save\n", '\000' <repeats 995 times>
,
  last_input = "' the reconnect\000lly\000on save", '\000' <repeats 484 times>,
  small_outbuf = "\e[1m\e[32m&w//&n Falkiner [Host:dial202.link.ca] has connecte
d.\r\n// Falkiner has 0 gold coins [0 in bank].\r\r\n\e[0m\e[1m\e[32m&w//&n Falk
iner has gained 100000000 experience.\r\n// Falkiner is 17 years of ag"...,
  output = 0x83c7cc0 "\e[1m\e[32m&w//&n Falkiner [Host:dial202.link.ca] has conn
ected.\r\n// Falkiner has 0 gold coins [0 in bank].\r\r\n\e[0m\e[1m\e[32m&w//&n
Falkiner has gained 100000000 experience.\r\n// Falkiner is 17 years of ag"...,
history = 0x83c9750, history_pos = 3, bufptr = 263, bufspace = 760,
  large_outbuf = 0x0, input = {head = 0x0, tail = 0x83cccc0},
    character = 0x83c9928, original = 0x0, snooping = 0x0, snoop_by = 0x0,
  next = 0x0, olc = 0x0, storage = 0x0}
(gdb) print *d->character
$4 = {pfilepos = 0, nr = -1, in_room = 763, was_in_room = -1, wait = 0,
  player = {passwd = "OdVV8RVVLs", name = 0x83c9908 "Odin", short_descr = 0x0,
    long_descr = 0x0, description = 0x0, title = 0x83c9918 "", sex = 1 '\001',
    chclass = 5 '\005', race = 5 '\005', level = 60 '<', hometown = 1, time = {
      birth = 929323133, logon = 929323133, played = 0}, weight = 129 '\201',
    height = 184 '¸'}, real_abils = {str = 25 '\031', str_add = 100 'd',
    intel = 25 '\031', wis = 25 '\031', dex = 25 '\031', con = 25 '\031',
    cha = 25 '\031'}, aff_abils = {str = 25 '\031', str_add = 100 'd',
    intel = 25 '\031', wis = 25 '\031', dex = 25 '\031', con = 25 '\031',
    cha = 25 '\031'}, points = {mana = 100, max_mana = 100, hit = 500,
    max_hit = 500, move = 82, max_move = 82, armor = 100, gold = 0,
    bank_gold = 0, exp = 7000000, hitroll = 0 '\000', damroll = 0 '\000'},
  char_specials = {fighting = 0x0, hunting = 0x0, position = 8 '\b',
    carry_weight = 0, carry_items = 0 '\000', timer = 0, saved = {
      alignment = 0, idnum = 1, act = 0, affected_by = 0,
      apply_saving_throw = {0, 0, 0, 0, 0}}}, player_specials = 0x83c9be0,
  mob_specials = {last_direction = 0 '\000', attack_type = 0,
    default_pos = 8 '\b', memory = 0x0, damnodice = 0 '\000',
    damsizedice = 0 '\000'}, affected = 0x0, equipment = {
    0x0 <repeats 20 times>}, carrying = 0x0, desc = 0x83c7668, id = 0,
  proto_script = 0x0, script = 0x0, memory = 0x0, next_in_room = 0x0,
  next = 0x83c7240, next_fighting = 0x0, followers = 0x0, master = 0x0,
  cmd = 0, cmd2 = 0}
(gdb)

Am i correct in thinking that this is pointing to load_char?
Seems that login (last) and birth are the same...
There are a bunch of 0x0 in there (being not created) this will take
me forever to figgure out...
if possible a little coaching would be excellent


>
>     (gdb) print d
>     ...
>     (gdb) print d->character
>     ...
>     (gdb) print *d
>     ...
>     (gdb) print *d->character
>
> Things to look for: NULL pointers (if d or d->character point to 0x0 then
> it hasn't been set to anything since it was CREATE()'d [1]) and memory
> overflows (if you have excessively high numbers for things that shouldn't
> be so high, etc.).  This will at least help you identify all the symptoms,
> which can help in identifying their cause.
>
> -dak

thanks again!

John Hines                    |   Weefcraft Custom Tiedyed Apparel
Founder/Coder                 |   Tiedye the way you want it!
TorbinMUD                     |     http://www.tiedye.org
torbinmud.rnrws.com 9191      |        weef@tiedye.org


     +------------------------------------------------------------+
     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     |  http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html  |
     +------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/15/00 PST