Changeset 49 in openpam


Ignore:
Timestamp:
Feb 13, 2002, 12:34:23 AM (16 years ago)
Author:
Dag-Erling Smørgrav
Message:

Fix an off-by-one bug that would in some circumstances trim off the
last character of a configuration line.

Sponsored by: DARPA, NAI Labs

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/pam_start.c

    r35 r49  
    133133                if ((p = strchr(buf, '#')) != NULL)
    134134                        len = p - buf ? p - buf - 1 : p - buf;
    135                 while (len > 0 && isspace(buf[len]))
     135                while (len > 0 && isspace(buf[len - 1]))
    136136                        --len;
    137137                if (len == 0)
Note: See TracChangeset for help on using the changeset viewer.