Recently I've been having an issue with the code shown below and it's been bugging me for a while now. I don't know why it's happening, the only thing I know is that the python code brings up a segfault on the line noted and gdb brings up something about memory. Am I doing something wrong or is this a bug? I'd really like to get this working, so if you can help I'd greatly appreciate it.
C++ code:
static int win_width = 364;
static int win_height = 478;
netlist = new wxDialog(NULL, wxID_ANY, "Network List", wxDefaultPosition, wxSize(win_width-8, win_height-8), wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER);
wxBoxSizer *hszr = new wxBoxSizer(wxHORIZONTAL),
*vszr = new wxBoxSizer(wxVERTICAL), *vszr2 = new wxBoxSizer(wxVERTICAL);
wxStaticBoxSizer* sszr = new wxStaticBoxSizer(wxVERTICAL, netlist, "User Information");
wxFlexGridSizer* fgszr = new wxFlexGridSizer(2);
fgszr->Add(new wxStaticText(sszr->GetStaticBox(), wxID_ANY, "Nick Name: "));
Python code:
win_width = 364
win_height = 478
netlist = wx.Dialog(None, wx.ID_ANY, "Network List", wx.DefaultPosition, wx.Size(win_width-8, win_height-8), wx.DEFAULT_DIALOG_STYLE|wx.RESIZE_BORDER)
hszr = wx.BoxSizer(wx.HORIZONTAL)
vszr = wx.BoxSizer(wx.VERTICAL)
vszr2 = wx.BoxSizer(wx.VERTICAL)
sszr = wx.StaticBoxSizer(wx.StaticBox(netlist, wx.ID_ANY, "User Information"), orient=wx.VERTICAL)
fgszr = wx.FlexGridSizer(2)
fgszr.Add(wx.StaticText(sszr.GetStaticBox(), wx.ID_ANY, "Nick Name: ")) # Segmentation Fault