diff options
author | Kalev Lember <klember@redhat.com> | 2016-09-01 10:28:33 +0200 |
---|---|---|
committer | Kalev Lember <klember@redhat.com> | 2016-09-01 14:56:02 +0200 |
commit | 06aa6244d8e5f6cf42ae5a0d4e3afa4649f19604 (patch) | |
tree | b49107de2db3b13bed7a4d7af2a0d43e587b4e97 /lib | |
parent | 088440d0e27f684cfe2a9cca61dfd1bdc3e3fc12 (diff) |
Add a new REPO_ALREADY_SET error enum and use it in backends
Instead of PK_ERROR_ENUM_REPO_NOT_AVAILABLE, return
PK_ERROR_ENUM_REPO_ALREADY_SET when we're trying to set a value and it's
already set the right way. This makes it possible to ignore the error in
the UI code.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/packagekit-glib2/pk-enum.c | 1 | ||||
-rw-r--r-- | lib/packagekit-glib2/pk-enum.h | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/lib/packagekit-glib2/pk-enum.c b/lib/packagekit-glib2/pk-enum.c index bdc9c3fd3..e7867b7da 100644 --- a/lib/packagekit-glib2/pk-enum.c +++ b/lib/packagekit-glib2/pk-enum.c @@ -198,6 +198,7 @@ static const PkEnumMatch enum_error[] = { {PK_ERROR_ENUM_CANCELLED_PRIORITY, "cancelled-priority"}, {PK_ERROR_ENUM_UNFINISHED_TRANSACTION, "unfinished-transaction"}, {PK_ERROR_ENUM_LOCK_REQUIRED, "lock-required"}, + {PK_ERROR_ENUM_REPO_ALREADY_SET, "repo-already-set"}, {0, NULL} }; diff --git a/lib/packagekit-glib2/pk-enum.h b/lib/packagekit-glib2/pk-enum.h index 8c5599ac6..4bf93df51 100644 --- a/lib/packagekit-glib2/pk-enum.h +++ b/lib/packagekit-glib2/pk-enum.h @@ -307,6 +307,7 @@ typedef enum { PK_ERROR_ENUM_CANCELLED_PRIORITY, PK_ERROR_ENUM_UNFINISHED_TRANSACTION, PK_ERROR_ENUM_LOCK_REQUIRED, + PK_ERROR_ENUM_REPO_ALREADY_SET, PK_ERROR_ENUM_LAST } PkErrorEnum; |