// initialize it with known data..
// that should wipe out dupes.
var filesize = this.execute("SELECT filesize FROM Attachment WHERE id = %d".printf(
- int.parse(sid)));
+ int.parse(sid)));
+
+ if (filesize=="") {
+ GLib.debug("Ignoring record id (missing in database) :%s", sid);
+ return;
+ }
if (int.parse(filesize) < 1) {
GLib.debug("Could not get filesize from id :%s = %s", sid,filesize);
Posix.exit(0);