code factorization: take 2

This commit is contained in:
Aurelien Foret 2006-02-07 21:33:09 +00:00
parent bbb48a85f0
commit c5aca9529f

View file

@ -492,8 +492,8 @@ int sync_prepare(pmtrans_t *trans, pmdb_t *db_local, PMList *dbs_sync, PMList **
/* figure out which one was requested in targets. If they both were, /* figure out which one was requested in targets. If they both were,
* then it's still an unresolvable conflict. */ * then it's still an unresolvable conflict. */
target = pm_list_is_strin(miss->depend.name, trans->targets); target = pm_list_is_strin(miss->target, trans->targets) ? miss->target : NULL;
depend = pm_list_is_strin(miss->target, trans->targets); depend = pm_list_is_strin(miss->depend.name, trans->targets) ? miss->depend.name : NULL;
if(depend && !target) { if(depend && !target) {
_alpm_log(PM_LOG_DEBUG, "%s is in the target list -- keeping it", _alpm_log(PM_LOG_DEBUG, "%s is in the target list -- keeping it",
miss->depend.name); miss->depend.name);