____longjmp_chk () in Ubuntu 18.04

Do you have a typical platform dependent issue you're battling with ? Ask it here. Make sure you mention your platform, compiler, and wxWidgets version.
raananb
Super wx Problem Solver
Super wx Problem Solver
Posts: 419
Joined: Fri Oct 27, 2006 4:35 pm
Location: Paris, France
Contact:

Re: ____longjmp_chk () in Ubuntu 18.04

Post by raananb » Fri Feb 14, 2020 9:54 pm

The installed webkit is libwebkitgtk-3.0-dev

ONEEYEMAN
Part Of The Furniture
Part Of The Furniture
Posts: 3896
Joined: Sat Apr 16, 2005 7:22 am
Location: USA, Ukraine

Re: ____longjmp_chk () in Ubuntu 18.04

Post by ONEEYEMAN » Fri Feb 14, 2020 11:06 pm

Hi,
And I presume it is the only one, right?

Then the only idea I have is to re-compile WebKit in debug mode and see if you can replicate the issue.

However, it will be hard to find exact set of options Ubuntu used to configure WebKit.

Did you try any other distro? Debian, Mint, Fedora?
Or downgrade Ubuntu version?

On second thought - you have a "dev" package". But do you have an actual WebKit installed?
Which packages do you have installed that contains "webkit" in its name? (Sorry I'm not a Ubuntu user - Gentoo here).

Thank you.

raananb
Super wx Problem Solver
Super wx Problem Solver
Posts: 419
Joined: Fri Oct 27, 2006 4:35 pm
Location: Paris, France
Contact:

Re: ____longjmp_chk () in Ubuntu 18.04

Post by raananb » Sat Feb 15, 2020 7:33 am

Hi,
Searching the installed packages discovers 49 items including 'webkit' in their names. So much for clarity.

Maybe the sample will make things clearer.

Thanks.

ONEEYEMAN
Part Of The Furniture
Part Of The Furniture
Posts: 3896
Joined: Sat Apr 16, 2005 7:22 am
Location: USA, Ukraine

Re: ____longjmp_chk () in Ubuntu 18.04

Post by ONEEYEMAN » Sat Feb 15, 2020 11:36 pm

Hi,
Also try another distribution.

Thank you.

raananb
Super wx Problem Solver
Super wx Problem Solver
Posts: 419
Joined: Fri Oct 27, 2006 4:35 pm
Location: Paris, France
Contact:

Re: ____longjmp_chk () in Ubuntu 18.04

Post by raananb » Tue Feb 18, 2020 12:30 pm

Hi,

I found a problem within gtk/webview_webkit.cpp:

Function wxgtk_webview_webkit_load_status(...) processes status WEBKIT_LOAD_FINISHED and status WEBKIT_LOAD_COMMITTED, but no other status.

The debugging shows that status WEBKIT_LOAD_FIRST_VISUALLY_NON_EMPTY_LAYOUT was received by this function, which has no code to process it.

This may be why the process fails.

ONEEYEMAN
Part Of The Furniture
Part Of The Furniture
Posts: 3896
Joined: Sat Apr 16, 2005 7:22 am
Location: USA, Ukraine

Re: ____longjmp_chk () in Ubuntu 18.04

Post by ONEEYEMAN » Tue Feb 18, 2020 3:50 pm

Hi,
This might be Ubuntu-specific.
Did you try any other distribution?

Thank you.

raananb
Super wx Problem Solver
Super wx Problem Solver
Posts: 419
Joined: Fri Oct 27, 2006 4:35 pm
Location: Paris, France
Contact:

Re: ____longjmp_chk () in Ubuntu 18.04

Post by raananb » Wed Feb 19, 2020 6:03 pm

Hi,

The problem is present in Mint, but Mint is based on Ubuntu...

Rpm-based distributions require some learning before a working system becomes available.

I did find a key information in the sample:

Code: Select all

/**
  * Callback invoked when a page is finished loading
  */
void WebFrame::OnDocumentLoaded(wxWebViewEvent& evt)
{
    //Only notify if the document is the main frame, not a subframe
    if(evt.GetURL() == m_browser->GetCurrentURL())
    {
        wxLogMessage("%s", "Document loaded; url='" + evt.GetURL() + "'");
    }
    UpdateState();
}
It looks like the comment applies to linux/gtk, but not to Windows & OSX, where the event is notified in subframes.

In my application, the processing of the browser/page is (currently) done in a subframe. I'll see if it can be ported to the main frame.

Thanks

ONEEYEMAN
Part Of The Furniture
Part Of The Furniture
Posts: 3896
Joined: Sat Apr 16, 2005 7:22 am
Location: USA, Ukraine

Re: ____longjmp_chk () in Ubuntu 18.04

Post by ONEEYEMAN » Wed Feb 19, 2020 6:28 pm

Hi,
It is possible that this was some kid of a future TODO.
Can you get rid of this "if()" condition and see if it works?

O do you mean that underlying WebKitGTK does not support this feature?
The we might have a documentation bug...

Thank you.

raananb
Super wx Problem Solver
Super wx Problem Solver
Posts: 419
Joined: Fri Oct 27, 2006 4:35 pm
Location: Paris, France
Contact:

Re: ____longjmp_chk () in Ubuntu 18.04

Post by raananb » Wed Feb 19, 2020 9:42 pm

Hi,

The code I posted is from the webview sample, not from the webkit. I have inserted my application code inside the webview sample, and it works under Linux/gtk as expected. The sample is a top-level display.

In my application, the code is in a frame two levels below the main frame. The 'if' statement you refer to does not exist in the "real" application.

The webview_webkit of gtk has a status 'WEBKIT_LOAD_FINISHED' which fires wxWebViewEvent event(wxEVT_WEBVIEW_LOADED, webKitCtrl->GetId(),url, target);

But upon execution of the application status goes from WEBKIT_LOAD_PROVISIONAL to WEBKIT_LOAD_COMMITTED, then displays a console error message 'Syntax error: unexpected identifier 'isDown' followed by status=WEBKIT_LOAD_FIRST VISUALLY_NON_EMPTY_LAYOUT and then fails with a segmentation error.

The last statut may well point at a frame-level issue.

Thanks

ONEEYEMAN
Part Of The Furniture
Part Of The Furniture
Posts: 3896
Joined: Sat Apr 16, 2005 7:22 am
Location: USA, Ukraine

Re: ____longjmp_chk () in Ubuntu 18.04

Post by ONEEYEMAN » Wed Feb 19, 2020 9:58 pm

Hi,
You said that when you drop your code in the sample - everything works?
So now - how can you break the modified sample?

Thank you.

raananb
Super wx Problem Solver
Super wx Problem Solver
Posts: 419
Joined: Fri Oct 27, 2006 4:35 pm
Location: Paris, France
Contact:

Re: ____longjmp_chk () in Ubuntu 18.04

Post by raananb » Sat Feb 22, 2020 3:10 pm

Hi,

I dont see what you mean by 'break the modified sample'.

BTW, you mentioned earlier a documentation bug.

I have not seen any mention of restriction about using wxWebView in a window which is not top-level, which is certainly not true for Windows and OSX. I built my application ignoring the issue of window/subwindow, and it executes perfectly in these two environments. The functions using wxWebView are not proposed in the Linux version.

I wonder why the mention "Only notify if the document is the main frame, not a subframe" figures as it is in the sample. It should mention Linux, and the same restriction should be present in the general documentation.

For my part, I will stop investigating this issue at my level.

Maybe post a bug?

Thanks for your cooperation.

ONEEYEMAN
Part Of The Furniture
Part Of The Furniture
Posts: 3896
Joined: Sat Apr 16, 2005 7:22 am
Location: USA, Ukraine

Re: ____longjmp_chk () in Ubuntu 18.04

Post by ONEEYEMAN » Sat Feb 22, 2020 7:55 pm

Hi,
What I mean is - how the sample can be modified in order to get the behaviour of your problem.
Because if the bug is filed you need a reproducible test case.

Thank you.

raananb
Super wx Problem Solver
Super wx Problem Solver
Posts: 419
Joined: Fri Oct 27, 2006 4:35 pm
Location: Paris, France
Contact:

Re: ____longjmp_chk () in Ubuntu 18.04

Post by raananb » Sat Feb 22, 2020 8:07 pm

Hi,

My point is that if the official documentation of wxWebView does not mention this restriction, then the warning in the sample points to a bug, at least as far as Linux is concerned.

As for injecting my code into the sample, I replaced the original url with a url pertinent to my application and replaced the code for OnDocumentLoaded of the sample with the application code for that event. The sample then produced the expected results, which shows that the problem with my application is not in the application code but elsewhere.

Thanks

Post Reply