Returning -1 is useless since we don't provide any way
to determine why it failed.

Signed-off-by: Andrew Gregory <[email protected]>
---
 lib/libalpm/handle.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/libalpm/handle.c b/lib/libalpm/handle.c
index 98420b0..b2a10c8 100644
--- a/lib/libalpm/handle.c
+++ b/lib/libalpm/handle.c
@@ -129,7 +129,7 @@ int _alpm_handle_lock(alpm_handle_t *handle)
 /** Remove a lock file */
 int _alpm_handle_unlock(alpm_handle_t *handle)
 {
-       ASSERT(handle->lockfile != NULL, return -1);
+       ASSERT(handle->lockfile != NULL, return 0);
        ASSERT(handle->lockfd >= 0, return 0);
 
        close(handle->lockfd);
-- 
2.6.3

Reply via email to