1
0
mirror of https://github.com/rkd77/elinks.git synced 2024-10-13 05:43:37 -04:00

[http] const in get_header_param

This commit is contained in:
Witold Filipczyk 2022-02-17 20:39:07 +01:00
parent e8ad0b5948
commit 74c2ebd12b
2 changed files with 3 additions and 3 deletions

View File

@ -299,7 +299,7 @@ a:
/* Parse string param="value", return value as new string or NULL if any
* error. */
char *
get_header_param(char *e, char *name)
get_header_param(char *e, const char *name)
{
char *n, *start;
@ -307,7 +307,7 @@ again:
while (*e && c_toupper(*e++) != c_toupper(*name));
if (!*e) return NULL;
n = name + 1;
n = (char *)(name + 1);
while (*n && c_toupper(*e) == c_toupper(*n)) e++, n++;
if (*n) goto again;

View File

@ -15,7 +15,7 @@ enum parse_header_param {
char *parse_header(char *, const char *, char **);
enum parse_header_param parse_header_param(char *, const char *, char **, int);
char *get_header_param(char *, char *);
char *get_header_param(char *, const char *);
#ifdef __cplusplus
}