Changeset 914 in openpam for trunk/lib/libpam
- Timestamp:
- Jan 21, 2017, 3:15:29 PM (4 years ago)
- Location:
- trunk/lib/libpam
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/lib/libpam/openpam_findenv.c
r913 r914 40 40 #endif 41 41 42 #include <errno.h> 42 43 #include <string.h> 43 44 … … 64 65 pamh->env[i][len] == '=') 65 66 RETURNN(i); 67 errno = ENOENT; 66 68 RETURNN(-1); 67 69 } -
trunk/lib/libpam/pam_getenv.c
r913 r914 40 40 #endif 41 41 42 #include <errno.h> 42 43 #include <stdlib.h> 43 44 #include <string.h> … … 62 63 63 64 ENTERS(name); 64 if (strchr(name, '=') != NULL) 65 if (strchr(name, '=') != NULL) { 66 errno = EINVAL; 65 67 RETURNS(NULL); 68 } 66 69 if ((i = openpam_findenv(pamh, name, strlen(name))) < 0) 67 70 RETURNS(NULL); -
trunk/lib/libpam/pam_putenv.c
r913 r914 40 40 #endif 41 41 42 #include <errno.h> 42 43 #include <stdlib.h> 43 44 #include <string.h> … … 65 66 66 67 /* sanity checks */ 67 if ((p = strchr(namevalue, '=')) == NULL) 68 if ((p = strchr(namevalue, '=')) == NULL) { 69 errno = EINVAL; 68 70 RETURNC(PAM_SYSTEM_ERR); 71 } 69 72 70 73 /* see if the variable is already in the environment */ -
trunk/lib/libpam/pam_setenv.c
r913 r914 40 40 #endif 41 41 42 #include <errno.h> 42 43 #include <stdlib.h> 43 44 #include <stdio.h> … … 68 69 69 70 /* sanity checks */ 70 if (*name == '\0' || strchr(name, '=') != NULL) 71 if (*name == '\0' || strchr(name, '=') != NULL) { 72 errno = EINVAL; 71 73 RETURNC(PAM_SYSTEM_ERR); 74 } 72 75 73 76 /* is it already there? */
Note: See TracChangeset
for help on using the changeset viewer.