Hi, All,

I have an application that repeatedly creates OpenKODE window and does something
and then destories it. The window destroy sequence is:
-----------------------------------
eglMakeCurrent(m_redInfo->egl_disp, EGL_NO_SURFACE, EGL_NO_SURFACE, EGL_NO_CONTEXT);
eglDestroyContext(m_redInfo->egl_disp, m_redInfo->egl_ctx);
eglDestroySurface(m_redInfo->egl_disp, m_redInfo->egl_surf);
kdDestroyWindow(m_redInfo->kd_win);
------------------------------------

However, it seems there is resourcce leak. Each loop, the process size increase.
After about 20 rounds of loop, the process hangs inside eglSwapBuffers().

If I destroy the kdWindow as this:
---------------------------------
eglMakeCurrent(m_redInfo->egl_disp, EGL_NO_SURFACE, EGL_NO_SURFACE,
EGL_NO_CONTEXT);
eglDestroyContext(m_redInfo->egl_disp, m_redInfo->egl_ctx);
eglDestroySurface(m_redInfo->egl_disp, m_redInfo->egl_surf);
kdDestroyWindow(m_redInfo->kd_win);
eglTerminate(m_redInfo->egl_disp);
eglReleaseThread();
---------------------------------
And call eglInitialize() again the second time, it still does not work.

Please inform what is the correct sequence to start kdWindow multiples with egl.