[Bug,debuginfod/31103] periodically malloc_trim()
Commit Message
https://sourceware.org/bugzilla/show_bug.cgi?id=31103
--- Comment #1 from Di Chen <dichen at redhat dot com> ---
Hey Frank,
Are you talking about a change like this?
```
fdcache.limit(0,0,0,0); // release the fdcache contents
```
@@ -69,6 +69,7 @@ extern "C" {
#include <unistd.h>
#include <fcntl.h>
#include <netdb.h>
+#include <malloc.h>
/* If fts.h is included before config.h, its indirect inclusions may not
@@ -4197,8 +4198,7 @@ void groom()
(void) statfs_free_enough_p(db_path, "database"); // report sqlite
filesystem size
- sqlite3_db_release_memory(db); // shrink the process if possible
- sqlite3_db_release_memory(dbq); // ... for both connections
+ malloc_trim(0);
debuginfod_pool_groom(); // and release any debuginfod_client objects we've
been holding onto