mirror of
https://github.com/opnsense/src.git
synced 2026-06-09 00:32:25 -04:00
Completed fixes with login_getcapsize().
This commit is contained in:
parent
93aa55544d
commit
f9074e29fc
1 changed files with 2 additions and 1 deletions
|
|
@ -476,7 +476,7 @@ login_getcapsize(login_cap_t *lc, const char *cap, rlim_t def, rlim_t error) {
|
|||
rlim_t val = STRTOV(res, &ep, 0);
|
||||
if ((res == NULL) || (res == ep) || errno)
|
||||
return error;
|
||||
switch (*ep) {
|
||||
switch (*ep++) {
|
||||
case 0: /* end of string */
|
||||
ep--;
|
||||
mult = 1;
|
||||
|
|
@ -496,6 +496,7 @@ login_getcapsize(login_cap_t *lc, const char *cap, rlim_t def, rlim_t error) {
|
|||
default:
|
||||
return error;
|
||||
}
|
||||
res = ep;
|
||||
tot += (val * mult);
|
||||
}
|
||||
return tot;
|
||||
|
|
|
|||
Loading…
Reference in a new issue