Module Name: xsrc Committed By: mlelstv Date: Sat Aug 15 13:20:54 UTC 2015
Modified Files: xsrc/external/mit/MesaLib/dist/src/util: ralloc.c Log Message: Use __attribute__((__destructor__)), not atexit, in shared objects. Recovered from our local changes to MesaLib7. To generate a diff of this commit: cvs rdiff -u -r1.1.1.1 -r1.2 xsrc/external/mit/MesaLib/dist/src/util/ralloc.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: xsrc/external/mit/MesaLib/dist/src/util/ralloc.c diff -u xsrc/external/mit/MesaLib/dist/src/util/ralloc.c:1.1.1.1 xsrc/external/mit/MesaLib/dist/src/util/ralloc.c:1.2 --- xsrc/external/mit/MesaLib/dist/src/util/ralloc.c:1.1.1.1 Thu Dec 18 06:02:09 2014 +++ xsrc/external/mit/MesaLib/dist/src/util/ralloc.c Sat Aug 15 13:20:54 2015 @@ -285,7 +285,7 @@ ralloc_parent(const void *ptr) static void *autofree_context = NULL; -static void +static void __attribute__((__destructor__)) autofree(void) { ralloc_free(autofree_context); @@ -296,7 +296,6 @@ ralloc_autofree_context(void) { if (unlikely(autofree_context == NULL)) { autofree_context = ralloc_context(NULL); - atexit(autofree); } return autofree_context; }