X-Git-Url: https://pd.if.org/git/?a=blobdiff_plain;f=lib%2Fnotes.c;h=b29cbc79f5438ad83a78c8c3952853a7aa0c73a9;hb=09c80a1f8918d888063f4d1a75921a99fe5f0b5c;hp=b337fd446756a320330519e6f6bfaa7a3a48eea1;hpb=5cc943f078123837c33a4eeebf6eb96a581ddb47;p=zpackage diff --git a/lib/notes.c b/lib/notes.c index b337fd4..b29cbc7 100644 --- a/lib/notes.c +++ b/lib/notes.c @@ -69,7 +69,7 @@ int64_t zpm_note(struct zpm *zpm, struct zpm_note *n, unsigned int flags) { n->path = colstring(st, 4); n->file = colstring(st, 5); n->ack = sqlite3_column_int(st, 6); - n->ts = sqlite3_column_int(st, 1); + n->ts = colstring(st, 1); n->id = sqlite3_column_int64(st, 0); id = n->id; break; @@ -87,7 +87,8 @@ void zpm_note_free(struct zpm_note *n) { free(n->pkgid); free(n->path); free(n->file); - n->note = n->pkgid = n->path = n->file = 0; + free(n->ts); + n->note = n->ts = n->pkgid = n->path = n->file = 0; } int zpm_notes_available(struct zpm *zpm, int flags) {