summaryrefslogtreecommitdiff
path: root/src/sss_client
diff options
context:
space:
mode:
authorSumit Bose <sbose@redhat.com>2010-11-05 14:57:13 +0100
committerStephen Gallagher <sgallagh@redhat.com>2010-11-15 15:37:30 -0500
commit4b498111c49b254e9aa5e2b0d4fcc1ba24a04236 (patch)
tree475ee706a527c23ba502af6f820c2c83ba128eae /src/sss_client
parentbe434625437ff3dd4cce83a655226c67943e5ceb (diff)
downloadsssd-4b498111c49b254e9aa5e2b0d4fcc1ba24a04236.tar.gz
sssd-4b498111c49b254e9aa5e2b0d4fcc1ba24a04236.tar.bz2
sssd-4b498111c49b254e9aa5e2b0d4fcc1ba24a04236.zip
Avoid long long in messages to PAM client use int64_t
Diffstat (limited to 'src/sss_client')
-rw-r--r--src/sss_client/pam_sss.c12
-rw-r--r--src/sss_client/sss_cli.h6
2 files changed, 9 insertions, 9 deletions
diff --git a/src/sss_client/pam_sss.c b/src/sss_client/pam_sss.c
index 644073f5..f7876c22 100644
--- a/src/sss_client/pam_sss.c
+++ b/src/sss_client/pam_sss.c
@@ -567,19 +567,19 @@ static int user_info_offline_auth(pam_handle_t *pamh, size_t buflen,
uint8_t *buf)
{
int ret;
- long long expire_date;
+ int64_t expire_date;
struct tm tm;
char expire_str[128];
char user_msg[256];
expire_str[0] = '\0';
- if (buflen != sizeof(uint32_t) + sizeof(long long)) {
+ if (buflen != sizeof(uint32_t) + sizeof(int64_t)) {
D(("User info response data has the wrong size"));
return PAM_BUF_ERR;
}
- memcpy(&expire_date, buf + sizeof(uint32_t), sizeof(long long));
+ memcpy(&expire_date, buf + sizeof(uint32_t), sizeof(int64_t));
if (expire_date > 0) {
if (localtime_r((time_t *) &expire_date, &tm) != NULL) {
@@ -690,19 +690,19 @@ static int user_info_offline_auth_delayed(pam_handle_t *pamh, size_t buflen,
uint8_t *buf)
{
int ret;
- long long delayed_until;
+ int64_t delayed_until;
struct tm tm;
char delay_str[128];
char user_msg[256];
delay_str[0] = '\0';
- if (buflen != sizeof(uint32_t) + sizeof(long long)) {
+ if (buflen != sizeof(uint32_t) + sizeof(int64_t)) {
D(("User info response data has the wrong size"));
return PAM_BUF_ERR;
}
- memcpy(&delayed_until, buf + sizeof(uint32_t), sizeof(long long));
+ memcpy(&delayed_until, buf + sizeof(uint32_t), sizeof(int64_t));
if (delayed_until <= 0) {
D(("User info response data has an invalid value"));
diff --git a/src/sss_client/sss_cli.h b/src/sss_client/sss_cli.h
index fcea8e64..f8ccb4f5 100644
--- a/src/sss_client/sss_cli.h
+++ b/src/sss_client/sss_cli.h
@@ -364,7 +364,7 @@ enum user_info_type {
* @param Time when the cached
* password will expire in seconds
* since the UNIX Epoch as returned
- * by time(2) as long long. A value
+ * by time(2) as int64_t. A value
* of zero indicates that the
* cached password will never
* expire. */
@@ -375,8 +375,8 @@ enum user_info_type {
* @param Time when an
* authentication is allowed again
* in seconds since the UNIX Epoch
- * as returned by time(2) as long
- * long. */
+ * as returned by time(2) as
+ * int64_t. */
SSS_PAM_USER_INFO_OFFLINE_CHPASS, /**< * Tell the user that it is not
* possible to change the password while
* the system is offline. This message