Git-Url: http://git.frugalware.org/gitweb/gitweb.cgi?p=pacman-g2.git;a=commitdiff;h=0640f6f0952319b48bcd5530dd10667cf619e125
commit 0640f6f0952319b48bcd5530dd10667cf619e125 Author: Michel Hermier <herm...@frugalware.org> Date: Tue Nov 12 14:53:15 2013 +0100 libpacman: Use _pacman_db_gettimestamp instead of _pacman_db_getlastupdate in check_olddelay. diff --git a/lib/libpacman/sync.c b/lib/libpacman/sync.c index 08c36bd..16d41c3 100644 --- a/lib/libpacman/sync.c +++ b/lib/libpacman/sync.c @@ -229,21 +229,15 @@ static int pkg_cmp(const void *p1, const void *p2) static int check_olddelay(void) { pmlist_t *i; - char lastupdate[16] = ""; struct tm tm; if(!handle->olddelay) { return(0); } - memset(&tm,0,sizeof(struct tm)); - for(i = handle->dbs_sync; i; i= i->next) { pmdb_t *db = i->data; - if(_pacman_db_getlastupdate(db, lastupdate) == -1) { - continue; - } - if(strptime(lastupdate, "%Y%m%d%H%M%S", &tm) == NULL) { + if(_pacman_db_gettimestamp(db, &tm) == -1) { continue; } if((time(NULL)-mktime(&tm)) > handle->olddelay) { _______________________________________________ Frugalware-git mailing list Frugalware-git@frugalware.org http://frugalware.org/mailman/listinfo/frugalware-git