--- a/src/internfile/mh_execm.cpp
+++ b/src/internfile/mh_execm.cpp
@@ -47,6 +47,9 @@
// Command name
string cmd = params.front();
+ int filtermaxmbytes = 0;
+ m_config->getConfParam("filtermaxmbytes", &filtermaxmbytes);
+
m_maxmemberkb = 50000;
m_config->getConfParam("membermaxkbs", &m_maxmemberkb);
ostringstream oss;
@@ -56,6 +59,8 @@
m_cmd.putenv("RECOLL_CONFDIR", m_config->getConfDir());
m_cmd.putenv(m_forPreview ? "RECOLL_FILTER_FORPREVIEW=yes" :
"RECOLL_FILTER_FORPREVIEW=no");
+
+ m_cmd.setrlimit_as(filtermaxmbytes);
// Build parameter list: delete cmd name
vector<string>myparams(params.begin() + 1, params.end());