function quarantine_deliver($list, $num,$rpc_only=false) {
if(!$rpc_only && is_local($list[0]['host']))
{
foreach($num as $key=>$val)
{
$file[$val] = $list[$val]['path'];
$newfile[$val] = '/var/spool/exim/input/'.$list[$val]['file'];
if (!copy($file[$val], $newfile[$val]))
{
// Error
$status = 'Deliver: error'.' F:'.$file[$val].' N:'.$newfile[$val];
$error = true;
} else {
$status = "Release: message released.";
audit_log('Quarantined message ('.$list[$val]['msgid'].') released.');
}
}
return($status);
} else {
// Host is remote - handle by RPC - this section not written
$status = "Not released: RPC delivery not written at this time.";
return($status);
}
}