[RFC,v1,02/10] libcamera: egl: Remove `eGL::surface_`
diff mbox series

Message ID 20260804101949.353266-3-barnabas.pocze@ideasonboard.com
State Superseded
Headers show
Series
  • libcamera: software_isp: debayer_egl: Remove some leaks
Related show

Commit Message

Barnabás Pőcze Aug. 4, 2026, 10:19 a.m. UTC
This member has always been unused, so remove it.

Signed-off-by: Barnabás Pőcze <barnabas.pocze@ideasonboard.com>
---
 include/libcamera/internal/egl.h | 1 -
 src/libcamera/egl.cpp            | 8 --------
 2 files changed, 9 deletions(-)

Comments

Milan Zamazal Aug. 5, 2026, 10 a.m. UTC | #1
Barnabás Pőcze <barnabas.pocze@ideasonboard.com> writes:

> This member has always been unused, so remove it.

Reviewed-by: Milan Zamazal <mzamazal@redhat.com>

> Signed-off-by: Barnabás Pőcze <barnabas.pocze@ideasonboard.com>
> ---
>  include/libcamera/internal/egl.h | 1 -
>  src/libcamera/egl.cpp            | 8 --------
>  2 files changed, 9 deletions(-)
>
> diff --git a/include/libcamera/internal/egl.h b/include/libcamera/internal/egl.h
> index c43684808d..f8ae486a8d 100644
> --- a/include/libcamera/internal/egl.h
> +++ b/include/libcamera/internal/egl.h
> @@ -133,7 +133,6 @@ private:
>  
>  	EGLDisplay display_ = EGL_NO_DISPLAY;
>  	EGLContext context_ = EGL_NO_CONTEXT;
> -	EGLSurface surface_ = EGL_NO_SURFACE;
>  
>  	int compileShader(int shaderType, GLuint &shaderId, Span<const unsigned char> shaderData,
>  			  Span<const std::string> shaderEnv);
> diff --git a/src/libcamera/egl.cpp b/src/libcamera/egl.cpp
> index 780b7bc2d5..900d2174df 100644
> --- a/src/libcamera/egl.cpp
> +++ b/src/libcamera/egl.cpp
> @@ -57,11 +57,6 @@ LOG_DEFINE_CATEGORY(eGL)
>   *\brief EGL context handle
>   */
>  
> -/**
> - *\var eGL::surface_
> - *\brief EGL sufrace handle
> - */
> -
>  /**
>   * \brief Construct an EGL helper
>   * \param[in] display The EGL display to use
> @@ -84,9 +79,6 @@ eGL::~eGL()
>  {
>  	if (context_ != EGL_NO_CONTEXT)
>  		eglDestroyContext(display_, context_);
> -
> -	if (surface_ != EGL_NO_SURFACE)
> -		eglDestroySurface(display_, surface_);
>  }
>  
>  /**

Patch
diff mbox series

diff --git a/include/libcamera/internal/egl.h b/include/libcamera/internal/egl.h
index c43684808d..f8ae486a8d 100644
--- a/include/libcamera/internal/egl.h
+++ b/include/libcamera/internal/egl.h
@@ -133,7 +133,6 @@  private:
 
 	EGLDisplay display_ = EGL_NO_DISPLAY;
 	EGLContext context_ = EGL_NO_CONTEXT;
-	EGLSurface surface_ = EGL_NO_SURFACE;
 
 	int compileShader(int shaderType, GLuint &shaderId, Span<const unsigned char> shaderData,
 			  Span<const std::string> shaderEnv);
diff --git a/src/libcamera/egl.cpp b/src/libcamera/egl.cpp
index 780b7bc2d5..900d2174df 100644
--- a/src/libcamera/egl.cpp
+++ b/src/libcamera/egl.cpp
@@ -57,11 +57,6 @@  LOG_DEFINE_CATEGORY(eGL)
  *\brief EGL context handle
  */
 
-/**
- *\var eGL::surface_
- *\brief EGL sufrace handle
- */
-
 /**
  * \brief Construct an EGL helper
  * \param[in] display The EGL display to use
@@ -84,9 +79,6 @@  eGL::~eGL()
 {
 	if (context_ != EGL_NO_CONTEXT)
 		eglDestroyContext(display_, context_);
-
-	if (surface_ != EGL_NO_SURFACE)
-		eglDestroySurface(display_, surface_);
 }
 
 /**