Startup Crash After Updating

Having problems with building or using CEF's C/C++ APIs? This forum is here to help. Please do not post bug reports or feature requests here.

Startup Crash After Updating

Postby Runt8 » Tue Jul 14, 2020 9:39 am

We are attempting to update our version of CEF from build 3626 to the latest build (4147). After fixing a handful of problems related to function signature changes, the application starts up but then crashes deep in libcef.dll. I don't have the libcef.dll.pdb so I don't have very good information about where it's crashing. The output log shows:

Code: Select all
[0714/082911.259:FATAL:http_util.cc(50)] Check failed: std::string::epos == language.find_first_of("; ") (18446744073709551615 vs. 1)


I'm assuming it's a resource problem but I believe I've copied all of the new resources to my working directory. Does anyone have any ideas?

Thanks!
Runt8
Techie
 
Posts: 29
Joined: Wed Dec 19, 2018 5:17 pm

Re: Startup Crash After Updating

Postby salvadordf » Tue Jul 14, 2020 10:05 am

At this moment, the stable branch is 4103.

The 4147 branch is in the beta channel.
Maintainer of the CEF4Delphi, WebView4Delphi, WebUI4Delphi and WebUI4CSharp projects.
User avatar
salvadordf
Expert
 
Posts: 129
Joined: Sun Dec 18, 2016 8:39 am
Location: Spain

Re: Startup Crash After Updating

Postby Runt8 » Wed Jul 15, 2020 6:05 pm

Thank you for your reply! I've changed to 4103 and am still seeing the same issue.
Runt8
Techie
 
Posts: 29
Joined: Wed Dec 19, 2018 5:17 pm

Re: Startup Crash After Updating

Postby magreenblatt » Wed Jul 15, 2020 6:29 pm

Does the sample app work as part of your build? Have you created a binary distribution from your build to assist with copying the necessary resources?
magreenblatt
Site Admin
 
Posts: 12409
Joined: Fri May 29, 2009 6:57 pm

Re: Startup Crash After Updating

Postby Runt8 » Wed Jul 15, 2020 8:22 pm

Yes, the sample app works.

Here is the process I use, which was pieced together from multiple forum posts and other sources. If there's a better way I would love to learn it!

My goal is to create a binary distribution identical to the official download, with two changes:
  1. h264 support
  2. A libcef_dll_wrapper that uses /MD for the Runtime Library (or /MDd for debug).

I mostly follow the instructions found on the MasterBuildQuickStart page. I add "is_official_build=true proprietary_codecs=true ffmpeg_branding=Chrome" to the update and the create scripts:

Code: Select all
set GN_DEFINES=is_official_build=true proprietary_codecs=true ffmpeg_branding=Chrome
set GN_ARGUMENTS=--ide=vs2017 --sln=cef --filters=//cef/*
set GYP_MSVS_VERSION=2017
set CEF_ARCHIVE_FORMAT=tar.bz2
python ..\automate\automate-git.py --download-dir=c:\code\chromium_git4103 --depot-tools-dir=c:\code\depot_tools --branch=4103 --minimal-distrib --client-distrib --force-clean --x64-build


Code: Select all
set GN_DEFINES=is_official_build=true proprietary_codecs=true ffmpeg_branding=Chrome
set GN_ARGUMENTS=--ide=vs2017 --sln=cef --filters=//cef/*
call cef_create_projects.bat


Then I call make_distrib.bat to make a distribution:
Code: Select all
make_distrib.bat --ninja-build --x64-build


From that distribution (in this case cef_binary_83.4.5+ga4a78d1+chromium-83.0.4103.106_windows64) i use cmake to generate the 64 bit VS project files. Then I open the project and change the runtime library for the libcef_dll_wrapper project, and recompile debug and release.

Then I copy the include files along with all the necessary dlls and resource files from the distribution to where my project expects them to be.

I did find the libcef pdb file, so I was able to load that and get a much nicer stack trace. I've attached the full stack trace, but it appears as though AcceptLanguageBuilder::AddLanguageCode is being called with "*;q=0.5" and the function doesn't like having the semi-colon in there.
StackTrace.PNG
StackTrace.PNG (531.43 KiB) Viewed 4000 times
Runt8
Techie
 
Posts: 29
Joined: Wed Dec 19, 2018 5:17 pm

Re: Startup Crash After Updating

Postby Runt8 » Wed Jul 15, 2020 8:38 pm

And...I figured out the problem :). I am the one setting the accept_language_list. Apparently I can no longer put Q values in it?

This used to work:
Code: Select all
string localeListString = "zh-Hans, en;q=0.8, *;0.5";
CefString( &settings.accept_language_list ).FromString( localeListString );
Runt8
Techie
 
Posts: 29
Joined: Wed Dec 19, 2018 5:17 pm


Return to Support Forum

Who is online

Users browsing this forum: Google [Bot] and 99 guests