From ece13f177d948013b6f3df926406c0cd947abc25 Mon Sep 17 00:00:00 2001 From: Werner Koch Date: Wed, 26 Oct 2016 09:02:10 +0200 Subject: common: Use GPG_ERR_INV_VALUE instead of GPG_ERR_EINVAL. * common/sysutils.c (gnupg_inotify_watch_socket): Return GPG_ERR_INV_VALUE for a missing socket name and set proper error source. -- By using a different value we can easier see whether the error is due to a system call or from GnuPG code. Signed-off-by: Werner Koch --- common/sysutils.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'common/sysutils.c') diff --git a/common/sysutils.c b/common/sysutils.c index ab3e1d6d5..3a08df774 100644 --- a/common/sysutils.c +++ b/common/sysutils.c @@ -988,7 +988,7 @@ gnupg_inotify_watch_socket (int *r_fd, const char *socket_name) *r_fd = -1; if (!socket_name) - return gpg_error (GPG_ERR_EINVAL); + return my_error (GPG_ERR_INV_VALUE); fname = xtrystrdup (socket_name); if (!fname) -- cgit v1.2.3