[gnu.g++.bug] a libg++ bug?

elkassas@eb.ele.tue.nl (sharif_el_kassas) (12/01/89)

Hi
I'm using libg++ ver 1.35.0 (May 8, 88), with g++ version 1.35.0
I found that the following example gives problems (a'core dumped')
-----
#include <CursesWindow.h>
//CursesWindow test(stdscr); // this is OK statics are 0 by default !
main(){
  CursesWindow test(stdscr); // this gives a 'core dumped' !
  test.addstr("stdscr test: ");
  test.refresh();
}
// compile with: g++ filename.cc -lg++ -lcurses -ltermcap
-----
I think this happens because CursesWindow::CursesWindow(WINDOW* &)
dos not initialize 'par' and 'sib' which confuses CursesWindow::~CursesWindow().
Replacing 'subwins = 0' by 'subwins = par = sib = 0' in
'CursesWindow(WINDOW* &)' seems to solve the problem!
What do u think?
Bye
Sherif Kassas