From d420d00081fb4cee8a17e723d167ff8e0a0862de Mon Sep 17 00:00:00 2001 From: Juan RP Date: Fri, 13 Feb 2009 00:18:28 +0100 Subject: [PATCH] xbps_unregister_repository: return ENOENT if not found, not ENODEV. --HG-- extra : convert_revision : c1be34bc1840ac351e8e2d301e2c71d247f0ea9c --- bin/xbps-repo/main.c | 2 +- lib/repository.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/xbps-repo/main.c b/bin/xbps-repo/main.c index 164ff9245f..0a9a133f70 100644 --- a/bin/xbps-repo/main.c +++ b/bin/xbps-repo/main.c @@ -265,7 +265,7 @@ main(int argc, char **argv) exit(EXIT_FAILURE); if (!xbps_unregister_repository(dpkgidx)) { - if (errno == ENODEV) + if (errno == ENOENT) printf("Repository '%s' not actually " "registered.\n", dpkgidx); else diff --git a/lib/repository.c b/lib/repository.c index a272a0b39a..537688fcdc 100644 --- a/lib/repository.c +++ b/lib/repository.c @@ -201,7 +201,7 @@ xbps_unregister_repository(const char *uri) } } else { /* Not found. */ - errno = ENODEV; + errno = ENOENT; } prop_object_release(dict);