Родитель
d60fa59b91
Коммит
9fff7feb82
|
@ -41,8 +41,8 @@ int Curl_strncasecompare(const char *first, const char *second, size_t max);
|
|||
char Curl_raw_toupper(char in);
|
||||
|
||||
/* checkprefix() is a shorter version of the above, used when the first
|
||||
argument is zero-byte terminated */
|
||||
#define checkprefix(a,b) curl_strnequal(a,b,strlen(a))
|
||||
argument is the string literal */
|
||||
#define checkprefix(a,b) curl_strnequal(b, STRCONST(a))
|
||||
|
||||
void Curl_strntoupper(char *dest, const char *src, size_t n);
|
||||
void Curl_strntolower(char *dest, const char *src, size_t n);
|
||||
|
|
|
@ -327,7 +327,7 @@ static CURLcode tftp_parse_option_ack(struct tftp_state_data *state,
|
|||
|
||||
infof(data, "got option=(%s) value=(%s)", option, value);
|
||||
|
||||
if(checkprefix(option, TFTP_OPTION_BLKSIZE)) {
|
||||
if(checkprefix(TFTP_OPTION_BLKSIZE, option)) {
|
||||
long blksize;
|
||||
|
||||
blksize = strtol(value, NULL, 10);
|
||||
|
@ -359,7 +359,7 @@ static CURLcode tftp_parse_option_ack(struct tftp_state_data *state,
|
|||
infof(data, "%s (%d) %s (%d)", "blksize parsed from OACK",
|
||||
state->blksize, "requested", state->requested_blksize);
|
||||
}
|
||||
else if(checkprefix(option, TFTP_OPTION_TSIZE)) {
|
||||
else if(checkprefix(TFTP_OPTION_TSIZE, option)) {
|
||||
long tsize = 0;
|
||||
|
||||
tsize = strtol(value, NULL, 10);
|
||||
|
|
Загрузка…
Ссылка в новой задаче