Changeset 4476:f5d7c266e5de in roaraudio for roard/auth.c
- Timestamp:
- 10/11/10 00:39:08 (14 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
roard/auth.c
r4474 r4476 38 38 39 39 // enable guest access. 40 if ( auth_ regkey_simple(ROAR_AUTH_T_NONE, ACCLEV_ALL) == NULL)40 if ( auth_addkey_anonymous(ACCLEV_ALL) == -1 ) 41 41 return -1; 42 43 #if 0 44 // test password for API tests... 45 auth_addkey_password(ACCLEV_ALL, "test"); 46 #endif 42 47 43 48 return 0; … … 128 133 } 129 134 135 int auth_addkey_anonymous(enum roard_client_acclev acclev) { 136 if ( auth_regkey_simple(ROAR_AUTH_T_NONE, acclev) == NULL ) 137 return -1; 138 return 0; 139 } 140 141 int auth_addkey_password(enum roard_client_acclev acclev, const char * password) { 142 union auth_typeunion * pw; 143 144 if ( (pw = auth_regkey_simple(ROAR_AUTH_T_PASSWORD, acclev)) == NULL ) 145 return -1; 146 147 pw->password.password = password; 148 149 return 0; 150 } 151 130 152 //ll
Note: See TracChangeset
for help on using the changeset viewer.