diff options
| author | alec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2009-07-19 09:28:30 +0000 |
|---|---|---|
| committer | alec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2009-07-19 09:28:30 +0000 |
| commit | 45ca96cd4bb2196818fde5cd42a8012a961a41c3 (patch) | |
| tree | 70527934310c2dd7f7d93b00fb10f1bfb91d26d7 /roundcubemail/plugins/database_attachments/database_attachments.php | |
| parent | b0e4195efc2f6b72a10f358c57c24973318abfd4 (diff) | |
- handle big attachments with file pointers to not exceed memory_limit in rcmail_save_attachment()
git-svn-id: https://svn.roundcube.net/trunk@2766 208e9e7b-5314-0410-a742-e7e81cd9613c
Diffstat (limited to 'roundcubemail/plugins/database_attachments/database_attachments.php')
| -rw-r--r-- | roundcubemail/plugins/database_attachments/database_attachments.php | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/roundcubemail/plugins/database_attachments/database_attachments.php b/roundcubemail/plugins/database_attachments/database_attachments.php index 28ccde4b3..a8ac62e26 100644 --- a/roundcubemail/plugins/database_attachments/database_attachments.php +++ b/roundcubemail/plugins/database_attachments/database_attachments.php @@ -63,6 +63,10 @@ class database_attachments extends filesystem_attachments $rcmail = rcmail::get_instance(); $key = $this->_key($args['name']); + + if ($args['path']) + $args['data'] = file_get_contents($args['path']); + $data = base64_encode($args['data']); $status = $rcmail->db->query( |
