aboutsummaryrefslogtreecommitdiff
path: root/login
diff options
context:
space:
mode:
Diffstat (limited to 'login')
-rw-r--r--login/getutid_r.c8
-rw-r--r--login/getutline_r.c2
-rw-r--r--login/login.c2
-rw-r--r--login/pututline_r.c2
4 files changed, 7 insertions, 7 deletions
diff --git a/login/getutid_r.c b/login/getutid_r.c
index 00dbec4..8107015 100644
--- a/login/getutid_r.c
+++ b/login/getutid_r.c
@@ -37,7 +37,7 @@ __getutid_r (const struct utmp *id, struct utmp **utmp,
&& id->ut_type != USER_PROCESS && id->ut_type != DEAD_PROCESS)
/* No, using '<' and '>' for the test is not possible. */
{
- errno = EINVAL;
+ __set_errno (EINVAL);
return -1;
}
@@ -66,7 +66,7 @@ __getutid_r (const struct utmp *id, struct utmp **utmp,
!= sizeof (struct utmp))
{
utmp_data->loc_utmp = 0; /* Mark loc_utmp invalid. */
- errno = ESRCH;
+ __set_errno (ESRCH);
return -1;
}
@@ -89,7 +89,7 @@ __getutid_r (const struct utmp *id, struct utmp **utmp,
!= sizeof (struct utmp))
{
utmp_data->loc_utmp = 0; /* Mark loc_utmp invalid. */
- errno = ESRCH;
+ __set_errno (ESRCH);
return -1;
}
@@ -110,7 +110,7 @@ __getutid_r (const struct utmp *id, struct utmp **utmp,
return 0;
#else /* !_HAVE_UT_ID && !_HAVE_UT_TYPE */
- errno = ENOSYS;
+ __set_errno (ENOSYS);
return -1;
#endif
}
diff --git a/login/getutline_r.c b/login/getutline_r.c
index e5c4196..e88267d 100644
--- a/login/getutline_r.c
+++ b/login/getutline_r.c
@@ -48,7 +48,7 @@ __getutline_r (const struct utmp *line, struct utmp **utmp,
!= sizeof (struct utmp))
{
utmp_data->loc_utmp = 0; /* Mark UTMP_DATA->ubuf invalid. */
- errno = ESRCH;
+ __set_errno (ESRCH);
return -1;
}
diff --git a/login/login.c b/login/login.c
index a53613f..00b176a 100644
--- a/login/login.c
+++ b/login/login.c
@@ -62,7 +62,7 @@ tty_name (int fd, char **tty, size_t buf_len)
if (! new_buf)
{
rv = -1;
- errno = ENOMEM;
+ __set_errno (ENOMEM);
break;
}
}
diff --git a/login/pututline_r.c b/login/pututline_r.c
index 55436bf..42ea3cd 100644
--- a/login/pututline_r.c
+++ b/login/pututline_r.c
@@ -45,7 +45,7 @@ __pututline_r (const struct utmp *id, struct utmp_data *utmp_data)
&& id->ut_type != USER_PROCESS && id->ut_type != DEAD_PROCESS)
/* No, using '<' and '>' for the test is not possible. */
{
- errno = EINVAL;
+ __set_errno (EINVAL);
return -1;
}
#endif