mirror of
https://gitlab.xiph.org/xiph/icecast-server.git
synced 2024-09-22 04:15:54 -04:00
Cleanup: mark key as const (why wasn't it const already?)
This commit is contained in:
parent
b55bae035d
commit
c0e895404e
@ -144,7 +144,7 @@ int matchfile_release(matchfile_t *file) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* we are not const char *key because of avl_get_by_key()... */
|
/* we are not const char *key because of avl_get_by_key()... */
|
||||||
int matchfile_match(matchfile_t *file, char *key) {
|
int matchfile_match(matchfile_t *file, const char *key) {
|
||||||
void *result;
|
void *result;
|
||||||
|
|
||||||
if (!file)
|
if (!file)
|
||||||
@ -159,7 +159,7 @@ int matchfile_match(matchfile_t *file, char *key) {
|
|||||||
return avl_get_by_key(file->contents, (void*)key, &result) == 0 ? 1 : 0;
|
return avl_get_by_key(file->contents, (void*)key, &result) == 0 ? 1 : 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
int matchfile_match_allow_deny(matchfile_t *allow, matchfile_t *deny, char *key) {
|
int matchfile_match_allow_deny(matchfile_t *allow, matchfile_t *deny, const char *key) {
|
||||||
if (!allow && !deny)
|
if (!allow && !deny)
|
||||||
return 1;
|
return 1;
|
||||||
|
|
||||||
|
@ -15,9 +15,9 @@ typedef struct matchfile_tag matchfile_t;
|
|||||||
matchfile_t *matchfile_new(const char *filename);
|
matchfile_t *matchfile_new(const char *filename);
|
||||||
int matchfile_addref(matchfile_t *file);
|
int matchfile_addref(matchfile_t *file);
|
||||||
int matchfile_release(matchfile_t *file);
|
int matchfile_release(matchfile_t *file);
|
||||||
int matchfile_match(matchfile_t *file, char *key);
|
int matchfile_match(matchfile_t *file, const char *key);
|
||||||
|
|
||||||
/* returns 1 for allow or pass and 0 for deny */
|
/* returns 1 for allow or pass and 0 for deny */
|
||||||
int matchfile_match_allow_deny(matchfile_t *allow, matchfile_t *deny, char *key);
|
int matchfile_match_allow_deny(matchfile_t *allow, matchfile_t *deny, const char *key);
|
||||||
|
|
||||||
#endif /* __MATCHFILE_H__ */
|
#endif /* __MATCHFILE_H__ */
|
||||||
|
Loading…
Reference in New Issue
Block a user