libalpm/deps.c: access trans flags directly

Signed-off-by: Dan McGee <dan@archlinux.org>
This commit is contained in:
Dan McGee 2012-01-18 22:09:43 -06:00
parent e50c4a8837
commit ac239c54d0
1 changed files with 4 additions and 2 deletions

View File

@ -202,8 +202,10 @@ alpm_list_t *_alpm_sortbydeps(alpm_handle_t *handle,
static int no_dep_version(alpm_handle_t *handle)
{
int flags = alpm_trans_get_flags(handle);
return flags != -1 && (flags & ALPM_TRANS_FLAG_NODEPVERSION);
if(!handle->trans) {
return 0;
}
return (handle->trans->flags & ALPM_TRANS_FLAG_NODEPVERSION);
}
static alpm_depend_t *filtered_depend(alpm_depend_t *dep, int nodepversion)