This is an automated email from the git hooks/post-receive script.

git pushed a commit to branch tymux-10-quiet-head
in repository terminology.

View the commit online.

commit ea7bef17c49e72da81b81a567b2dbb97ab034094
Author: Boris Faure <[email protected]>
AuthorDate: Fri Oct 30 15:58:33 2026 +0000

    tytest: drain eina's main freeq on the unit-test path
    
    ecore_shutdown() does not free the eo class structures and vtables
    directly: it queues them on eina's main freeq, which a running main
    loop drains. The escape-code tests get that loop; the unit-test path
    returns from main() without one, so the queued frees never run and
    LeakSanitizer reports the memory as leaked. Drain the queue explicitly
    before returning.
---
 src/bin/tytest.c | 13 +++++++++++--
 1 file changed, 11 insertions(+), 2 deletions(-)

diff --git a/src/bin/tytest.c b/src/bin/tytest.c
index e48343d6..b0dbc0c6 100644
--- a/src/bin/tytest.c
+++ b/src/bin/tytest.c
@@ -856,7 +856,7 @@ main(int argc, char **argv)
 {
    Eina_Bool dump = EINA_FALSE;
    int chunk = 0;
-   int i;
+   int i, res;
 
    /* Before the argument loop: the unit-test path returns out of it without
     * ever reaching tytest_common_init(), and several of those tests drive the
@@ -876,7 +876,16 @@ main(int argc, char **argv)
         else if (!strcmp(argv[i], "--dump")) dump = EINA_TRUE;
         else if (!strncmp(argv[i], "--chunk=", 8)) chunk = atoi(argv[i] + 8);
         /* Anything else is a unit test name, and those take over entirely. */
-        else return _run_tytests(argc, argv);
+        else
+          {
+             res = _run_tytests(argc, argv);
+             /* Unit tests may run ecore_shutdown(), which queues the eo
+              * class and vtable frees on eina's main freeq. A running main
+              * loop drains that queue; there is none on this path, so the
+              * queued memory would be reported as leaked. */
+             eina_freeq_clear(eina_freeq_main_get());
+             return res;
+          }
      }
 
    emile_init();

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.

Reply via email to