Re: Patch: Auto-generate search_path statement for selected schema in query editor - Mailing list pgadmin-hackers

From Neel Patel
Subject Re: Patch: Auto-generate search_path statement for selected schema in query editor
Date
Msg-id CAMcbDBF5iT3rR-vZYXDkW2ficDEdFHV5NpzTC9Mg5dTAM1fvWg@mail.gmail.com
Whole thread Raw
In response to Re: Patch: Auto-generate search_path statement for selected schema in query editor  (Ashesh Vashi <ashesh.vashi@enterprisedb.com>)
Responses Re: Patch: Auto-generate search_path statement for selected schema in query editor  (Dave Page <dpage@pgadmin.org>)
List pgadmin-hackers
Hi,

We have checked the bug and below is our finding.

As we are getting the pane information from the manager and pane could not be found in the manager so at that time wxAuiPaneInfo structure is not valid and when we call Update() then it was crashing. So before calling to Update() we put check for validating the wxAuxPaneInfo structure as below.

wxAuiPaneInfo outputPaneInfo = manager.GetPane(wxT("outputPane")).Show(false);

wxAuiPaneInfo scratchPad = manager.GetPane(wxT("scratchPad")).Show(false);

viewMenu->Enable(MNU_OUTPUTPANE, false);

viewMenu->Enable(MNU_SCRATCHPAD, false);

if (outputPaneInfo.IsOk() == true && scratchPad.IsOk() == true)

    manager.Update();


Please find the patch along with this email and let me know.

Thanks,

Neel Patel




On Wed, Mar 6, 2013 at 11:54 AM, Ashesh Vashi <ashesh.vashi@enterprisedb.com> wrote:
On Tue, Feb 19, 2013 at 6:53 PM, Dave Page <dpage@pgadmin.org> wrote:
On Mon, Feb 18, 2013 at 11:10 PM, Florian Klaar <flo.klaar@gmx.de> wrote:
>
>> I can't reproduce that here on Mac. Can you get a backtrace?
> Not that easily, it seems. If I'm not mistaken you'd have to tell me how
> to build a debug target for wxWidgets 2.8 in VC2010 because without it,
> I can't build the pgAdmin debug target.

If you build wxWidgets using the script (which I recall you had
problems with - which I'll be looking into soon as I need to build a
new Windows VM), then it'll automatically create debug binaries. If
you use the IDE, then just do a batch build and ensure you select both
the debug and release targets for all the sub-projects.

> From what I can tell when
> running the release target though, it seems to be related to the UI - VC
> breaks in frmQuery::OnChangeNotebook() at
> viewMenu->Enable(MNU_OUTPUTPANE, false);
> and the stack trace leads into wxWidgets territory.

OK, I can reproduce it on Windows. It's actually the line before - the
manager.Update() call that it's crashing in. Not sure why though; I
guess it doesn't like being called while the tab is updating on
Windows.

Ashesh; can you or one of the team take a look at this please?

Thanks.


Neel,

Can you please take a look at this?

-- Ashesh 
--
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake

EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company



--
--

Thanks & Regards,

Ashesh Vashi
EnterpriseDB INDIA:
Enterprise PostgreSQL Company

 

http://www.linkedin.com/in/asheshvashi


Attachment

pgadmin-hackers by date:

Previous
From: Guillaume Lelarge
Date:
Subject: pgAdmin III commit: Add smallserial handling
Next
From: Dave Page
Date:
Subject: Re: Patch: Auto-generate search_path statement for selected schema in query editor