-CLASSIFY: {
- # Transform window pointer addresses so it's easier to compare logs
- $awaiting = "curscr" if ($_ =~ /creating curscr/);
- $awaiting = "newscr" if ($_ =~ /creating newscr/);
- $awaiting = "stdscr" if ($_ =~ /creating stdscr/);
- if ($_ =~ /^create :window 0x([0-9a-f]+)/) {
- $addr = "0x$1";
- if ($awaiting eq "curscr") {
- $curscr = $addr;
- } elsif ($awaiting eq "newscr") {
- $newscr = $addr;
- } elsif ($awaiting eq "stdscr") {
- $stdscr = $addr;
- } else {
- $win_addr[$win_nums] = $addr;
- $win_nums = $win_nums + 1;
- }
- $awaiting = "";
- } elsif ($_ =~ /^\.\.\.deleted win=0x([0-9a-f]+)/) {
- $addr = "0x$1";
- $_ = &transaddr($_);
- if ($addr eq $curscr) {
- $curscr = "";
- } elsif ($addr eq $newscr) {
- $newscr = "";
- } elsif ($addr eq $stdscr) {
- $stdscr = "";
- } else {
- for $n (0..$#win_addr) {
- if ($win_addr[$n] eq $addr) {
- $win_addr[$n] = "";
- }
- }
- }
- }
+ # Transform window pointer addresses so it's easier to compare logs
+ $awaiting = "curscr" if ( $_ =~ /creating curscr/ );
+ $awaiting = "newscr" if ( $_ =~ /creating newscr/ );
+ $awaiting = "stdscr" if ( $_ =~ /creating stdscr/ );
+ $awaiting = "screen" if ( $_ =~ /^(\+ )*called {new_prescr\(\)/ );
+ if ( $_ =~ /^create :window 0x([[:xdigit:]]+)/ ) {
+ $addr = "0x$1";
+ if ( $awaiting eq "curscr" ) {
+ $curscr = $addr;
+ }
+ elsif ( $awaiting eq "newscr" ) {
+ $newscr = $addr;
+ }
+ elsif ( $awaiting eq "stdscr" ) {
+ $stdscr = $addr;
+ }
+ else {
+ $win_addr{$addr} = $win_nums++;
+ }
+ $awaiting = "";
+ }
+ elsif ( $_ =~ /^(\+ )*called {_nc_add_to_try\((0x[[:xdigit:]]+),/ ) {
+ $try_addr{$2} = ++$try_nums unless defined $try_addr{$2};
+ }
+ elsif ( $_ =~ /^(\+ )*return }0x([[:xdigit:]]+)/ ) {
+ $addr = "0x$2";
+ if ( $awaiting eq "screen" ) {
+ $scr_addr{$addr} = ++$scr_nums;
+ }
+ }
+ elsif ( $_ =~ /^\.\.\.deleted win=0x([[:xdigit:]]+)/ ) {
+ $addr = "0x$1";
+ $_ = &transaddr($_);
+ if ( $addr eq $curscr ) {
+ $curscr = "";
+ }
+ elsif ( $addr eq $newscr ) {
+ $newscr = "";
+ }
+ elsif ( $addr eq $stdscr ) {
+ $stdscr = "";
+ }
+ else {
+ undef $win_addr{$addr};
+ }
+ }