mirror of
https://github.com/guanzhi/GmSSL.git
synced 2026-05-11 10:56:17 +08:00
Update src
This commit is contained in:
13
src/debug.c
13
src/debug.c
@@ -120,6 +120,19 @@ int format_bytes(FILE *fp, int format, int indent, const char *str, const uint8_
|
||||
}
|
||||
|
||||
|
||||
int format_string(FILE *fp, int fmt, int ind, const char *label, const uint8_t *d, size_t dlen)
|
||||
{
|
||||
while (ind--) {
|
||||
fprintf(fp, " ");
|
||||
}
|
||||
fprintf(fp, "%s: ", label);
|
||||
while (dlen--) {
|
||||
fprintf(fp, "%c", *d++);
|
||||
}
|
||||
fprintf(fp, "\n");
|
||||
return 1;
|
||||
}
|
||||
|
||||
int tls_trace(int format, int indent, const char *str, ...)
|
||||
{
|
||||
FILE *fp = stderr;
|
||||
|
||||
Reference in New Issue
Block a user