Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/pacman/conf.h2
-rw-r--r--src/pacman/pacman.c4
-rw-r--r--src/pacman/query.c4
3 files changed, 5 insertions, 5 deletions
diff --git a/src/pacman/conf.h b/src/pacman/conf.h
index e263d7c6..3ba49eae 100644
--- a/src/pacman/conf.h
+++ b/src/pacman/conf.h
@@ -187,7 +187,7 @@ enum {
/** package locality */
enum {
PKG_LOCALITY_UNSET = 0,
- PKG_LOCALITY_LOCAL = (1 << 0),
+ PKG_LOCALITY_NATIVE = (1 << 0),
PKG_LOCALITY_FOREIGN = (1 << 1)
};
diff --git a/src/pacman/pacman.c b/src/pacman/pacman.c
index 9c917f9d..70001269 100644
--- a/src/pacman/pacman.c
+++ b/src/pacman/pacman.c
@@ -512,11 +512,11 @@ static int parsearg_query(int opt)
break;
case OP_FOREIGN:
case 'm':
- config->op_q_locality |= PKG_LOCALITY_LOCAL;
+ config->op_q_locality |= PKG_LOCALITY_FOREIGN;
break;
case OP_NATIVE:
case 'n':
- config->op_q_locality |= PKG_LOCALITY_FOREIGN;
+ config->op_q_locality |= PKG_LOCALITY_NATIVE;
break;
case OP_OWNS:
case 'o':
diff --git a/src/pacman/query.c b/src/pacman/query.c
index 518b76ab..bd50b059 100644
--- a/src/pacman/query.c
+++ b/src/pacman/query.c
@@ -241,7 +241,7 @@ static unsigned short pkg_get_locality(alpm_pkg_t *pkg)
for(j = sync_dbs; j; j = alpm_list_next(j)) {
if(alpm_db_get_pkg(j->data, pkgname)) {
- return PKG_LOCALITY_LOCAL;
+ return PKG_LOCALITY_NATIVE;
}
}
return PKG_LOCALITY_FOREIGN;
@@ -275,7 +275,7 @@ static int filter(alpm_pkg_t *pkg)
return 0;
}
/* check if this pkg is or isn't in a sync DB */
- if(config->op_q_locality && config->op_q_locality & pkg_get_locality(pkg)) {
+ if(config->op_q_locality && config->op_q_locality != pkg_get_locality(pkg)) {
return 0;
}
/* check if this pkg is unrequired */