summaryrefslogtreecommitdiff
path: root/modules/pam_limits/pam_limits.c
diff options
context:
space:
mode:
authorThorsten Kukuk <kukuk@thkukuk.de>2004-09-24 09:18:21 +0000
committerThorsten Kukuk <kukuk@thkukuk.de>2004-09-24 09:18:21 +0000
commit128ded83a0d1d3b5a85b4c20a6c35d9481e23ce5 (patch)
treefdd298658b3808d85fe99fab062b911c9f2aeee6 /modules/pam_limits/pam_limits.c
parentc485b54636a6d93bdc9c9d82051db97d7dd53c71 (diff)
Relevant BUGIDs:
Purpose of commit: Commit summary: --------------- bugfix: Fix lot of compiler warnings new feature: add broken_shadow option to pam_unix (patch from Linux distributions)
Diffstat (limited to 'modules/pam_limits/pam_limits.c')
-rw-r--r--modules/pam_limits/pam_limits.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/modules/pam_limits/pam_limits.c b/modules/pam_limits/pam_limits.c
index 0d7f2185..536446bd 100644
--- a/modules/pam_limits/pam_limits.c
+++ b/modules/pam_limits/pam_limits.c
@@ -311,7 +311,7 @@ static void process_limit(int source, const char *lim_type,
int limit_item;
int limit_type = 0;
long limit_value;
- const char **endptr = &lim_value;
+ char *endptr;
const char *value_orig = lim_value;
if (ctrl & PAM_DEBUG_ARG)
@@ -367,14 +367,10 @@ static void process_limit(int source, const char *lim_type,
return;
}
- /*
- * there is a warning here because the library prototype for this
- * function is incorrect.
- */
- limit_value = strtol(lim_value, endptr, 10);
+ limit_value = strtol (lim_value, &endptr, 10);
/* special case value when limiting logins */
- if (limit_value == 0 && value_orig == *endptr) { /* no chars read */
+ if (limit_value == 0 && value_orig == endptr) { /* no chars read */
if (strcmp(lim_value,"-") != 0) {
_pam_log(LOG_DEBUG,"wrong limit value '%s'", lim_value);
return;