Changeset 474 in openpam for trunk


Ignore:
Timestamp:
Nov 3, 2011, 10:56:10 AM (8 years ago)
Author:
Dag-Erling Smørgrav
Message:

Fix the case where match_word() matches the last word on the line. It
would previously return 0 because it expected the next character after
the matched word to be a space.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/openpam_configure.c

    r460 r474  
    7777        while (*str && tolower(*str) == tolower(*word))
    7878                ++str, ++word;
    79         return (*str == ' ' && *word == '\0');
     79        return ((*str == ' ' || *str == '\0') && *word == '\0');
    8080}
    8181
Note: See TracChangeset for help on using the changeset viewer.