//var create_dir = this.created_dir;
- if (rs != null && rs.num_rows() > 0) {
+ if (rs == null || rs.num_rows() < 1) {
+ GLib.debug("ERROR - file size of write to stream returned 0?");
+ Posix.unlink(fn);
+ return;
+
+ }
file_id = row[0];
//create_dir = row[1];
//GLib.debug("msgid %s", row[2]);
'%s', -- in_mailfort_sig varchar(64)
) as result
-
-
- INSERT INTO
- Attachment
- (
- queue_id,
- mime_charset,
- mime_cdisp,
- mime_size,
-
- mime_is_cover,
- mime_is_multi,
- mime_is_mail,
-
- msgid,
- maillog_id,
- delivered,
-
-
- checksum,
- filesize,
- stored_filename,
-
- created,
- mime_filename,
- mime_type,
-
-
- )
- VALUES
- (
- COALESCE((SELECT id from MailQueue where msgid = '%s' AND message_sig = '%s' AND msgid != '' AND message_sig != '' LIMIT 1),0),
- '%s',
- '%s',
- %d,
-
- 0,
- 0,
- 0,
-
- '%s',
- COALESCE((SELECT id from email_log where msgid = '%s' AND message_sig = '%s' AND msgid != '' AND message_sig != '' LIMIT 1),0),
- '%s',
-
- '%s',
- %d,
- '%s',
-
- '%s',
- '%s',
- '%s'
-
- )
-
""".printf(
+
this.mysql_escape(this.active_message_exim_id), this.mysql_escape(this.active_message_x_mailfort_sig),
"",
"attachment",