Bug 239760 - PlatformDisplay::PlatformDisplay(GdkDisplay* display) does not set m_eglDisplay to EGL_NO_DISPLAY
Summary: PlatformDisplay::PlatformDisplay(GdkDisplay* display) does not set m_eglDispl...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKitGTK (show other bugs)
Version: WebKit Local Build
Hardware: PC Linux
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-04-26 00:40 PDT by Xi Ruoyao
Modified: 2022-04-26 11:52 PDT (History)
2 users (show)

See Also:


Attachments
Patch (1.58 KB, patch)
2022-04-26 05:05 PDT, Xi Ruoyao
no flags Details | Formatted Diff | Diff
Patch (1.52 KB, patch)
2022-04-26 08:40 PDT, Xi Ruoyao
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Xi Ruoyao 2022-04-26 00:40:27 PDT
The value of PlatformDisplay::m_eglDisplay is left with a random value, then triggers

    EGLDisplay Initialization failed: EGL_BAD_DISPLAY

in PlatformDisplay::initializeEGLDisplay.
Comment 1 Xi Ruoyao 2022-04-26 05:05:42 PDT
Created attachment 458354 [details]
Patch
Comment 2 Michael Catanzaro 2022-04-26 08:30:58 PDT
Comment on attachment 458354 [details]
Patch

Oops.

This change looks safe and good. But could you please use the initializer list, as in the constructor above?
Comment 3 Xi Ruoyao 2022-04-26 08:40:40 PDT
Created attachment 458371 [details]
Patch
Comment 4 Xi Ruoyao 2022-04-26 08:44:20 PDT
(In reply to Michael Catanzaro from comment #2)
> Comment on attachment 458354 [details]
> Patch
> 
> Oops.
> 
> This change looks safe and good. But could you please use the initializer
> list, as in the constructor above?

Updated.  I initially didn't like a "," leading the line but now I've found out WebKit widely uses initializer lists with such a format.
Comment 5 EWS 2022-04-26 11:52:36 PDT
Committed r293441 (249996@main): <https://commits.webkit.org/249996@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 458371 [details].