mirror of
https://github.com/curl/curl.git
synced 2026-08-24 12:33:37 +03:00
tidy-up: miscellaneous
- INSTALL-CMAKE.md: add missing periods, text fixes. - md4, md5: sync variables names. - curl_trc: sync an argument type. - docs/examples: sync debug/trace function copies, constify, tidy-ups. - replace commented code with `#if 0`. - drop redundant parenthesis (macro values, `return`, around single variables, function calls). - fix indentation, apply clang-format in places. Closes #20481
This commit is contained in:
parent
ca5efd02b6
commit
3003c32cb2
62 changed files with 291 additions and 281 deletions
30
lib/ws.c
30
lib/ws.c
|
|
@ -58,18 +58,18 @@
|
|||
|N|V|V|V| |
|
||||
| |1|2|3| |
|
||||
*/
|
||||
#define WSBIT_FIN (0x80)
|
||||
#define WSBIT_RSV1 (0x40)
|
||||
#define WSBIT_RSV2 (0x20)
|
||||
#define WSBIT_RSV3 (0x10)
|
||||
#define WSBIT_FIN 0x80
|
||||
#define WSBIT_RSV1 0x40
|
||||
#define WSBIT_RSV2 0x20
|
||||
#define WSBIT_RSV3 0x10
|
||||
#define WSBIT_RSV_MASK (WSBIT_RSV1 | WSBIT_RSV2 | WSBIT_RSV3)
|
||||
#define WSBIT_OPCODE_CONT (0x0)
|
||||
#define WSBIT_OPCODE_TEXT (0x1)
|
||||
#define WSBIT_OPCODE_BIN (0x2)
|
||||
#define WSBIT_OPCODE_CLOSE (0x8)
|
||||
#define WSBIT_OPCODE_PING (0x9)
|
||||
#define WSBIT_OPCODE_PONG (0xa)
|
||||
#define WSBIT_OPCODE_MASK (0xf)
|
||||
#define WSBIT_OPCODE_CONT 0x0
|
||||
#define WSBIT_OPCODE_TEXT 0x1
|
||||
#define WSBIT_OPCODE_BIN 0x2
|
||||
#define WSBIT_OPCODE_CLOSE 0x8
|
||||
#define WSBIT_OPCODE_PING 0x9
|
||||
#define WSBIT_OPCODE_PONG 0xa
|
||||
#define WSBIT_OPCODE_MASK 0xf
|
||||
|
||||
#define WSBIT_MASK 0x80
|
||||
|
||||
|
|
@ -387,7 +387,9 @@ static CURLcode ws_dec_read_head(struct ws_decoder *dec,
|
|||
}
|
||||
|
||||
dec->head_len = 1;
|
||||
/* ws_dec_info(dec, data, "seeing opcode"); */
|
||||
#if 0
|
||||
ws_dec_info(dec, data, "seeing opcode");
|
||||
#endif
|
||||
continue;
|
||||
}
|
||||
else if(dec->head_len == 1) {
|
||||
|
|
@ -439,7 +441,9 @@ static CURLcode ws_dec_read_head(struct ws_decoder *dec,
|
|||
Curl_bufq_skip(inraw, 1);
|
||||
++dec->head_len;
|
||||
if(dec->head_len < dec->head_total) {
|
||||
/* ws_dec_info(dec, data, "decoding head"); */
|
||||
#if 0
|
||||
ws_dec_info(dec, data, "decoding head");
|
||||
#endif
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue