summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/bio/bio_cb.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/libcrypto/bio/bio_cb.c')
-rw-r--r--src/lib/libcrypto/bio/bio_cb.c30
1 files changed, 15 insertions, 15 deletions
diff --git a/src/lib/libcrypto/bio/bio_cb.c b/src/lib/libcrypto/bio/bio_cb.c
index a272bf969a..133d2b77dc 100644
--- a/src/lib/libcrypto/bio/bio_cb.c
+++ b/src/lib/libcrypto/bio/bio_cb.c
@@ -76,62 +76,62 @@ BIO_debug_callback(BIO *bio, int cmd, const char *argp, int argi, long argl,
76 if (BIO_CB_RETURN & cmd) 76 if (BIO_CB_RETURN & cmd)
77 r = ret; 77 r = ret;
78 78
79 (void) snprintf(buf, sizeof buf, "BIO[%08lX]:", (unsigned long)bio); 79 snprintf(buf, sizeof buf, "BIO[%08lX]:", (unsigned long)bio);
80 p = &(buf[14]); 80 p = &(buf[14]);
81 p_maxlen = sizeof buf - 14; 81 p_maxlen = sizeof buf - 14;
82 switch (cmd) { 82 switch (cmd) {
83 case BIO_CB_FREE: 83 case BIO_CB_FREE:
84 (void) snprintf(p, p_maxlen, "Free - %s\n", bio->method->name); 84 snprintf(p, p_maxlen, "Free - %s\n", bio->method->name);
85 break; 85 break;
86 case BIO_CB_READ: 86 case BIO_CB_READ:
87 if (bio->method->type & BIO_TYPE_DESCRIPTOR) 87 if (bio->method->type & BIO_TYPE_DESCRIPTOR)
88 (void) snprintf(p, p_maxlen, 88 snprintf(p, p_maxlen,
89 "read(%d,%lu) - %s fd=%d\n", 89 "read(%d,%lu) - %s fd=%d\n",
90 bio->num, (unsigned long)argi, 90 bio->num, (unsigned long)argi,
91 bio->method->name, bio->num); 91 bio->method->name, bio->num);
92 else 92 else
93 (void) snprintf(p, p_maxlen, "read(%d,%lu) - %s\n", 93 snprintf(p, p_maxlen, "read(%d,%lu) - %s\n",
94 bio->num, (unsigned long)argi, bio->method->name); 94 bio->num, (unsigned long)argi, bio->method->name);
95 break; 95 break;
96 case BIO_CB_WRITE: 96 case BIO_CB_WRITE:
97 if (bio->method->type & BIO_TYPE_DESCRIPTOR) 97 if (bio->method->type & BIO_TYPE_DESCRIPTOR)
98 (void) snprintf(p, p_maxlen, 98 snprintf(p, p_maxlen,
99 "write(%d,%lu) - %s fd=%d\n", 99 "write(%d,%lu) - %s fd=%d\n",
100 bio->num, (unsigned long)argi, 100 bio->num, (unsigned long)argi,
101 bio->method->name, bio->num); 101 bio->method->name, bio->num);
102 else 102 else
103 (void) snprintf(p, p_maxlen, "write(%d,%lu) - %s\n", 103 snprintf(p, p_maxlen, "write(%d,%lu) - %s\n",
104 bio->num, (unsigned long)argi, bio->method->name); 104 bio->num, (unsigned long)argi, bio->method->name);
105 break; 105 break;
106 case BIO_CB_PUTS: 106 case BIO_CB_PUTS:
107 (void) snprintf(p, p_maxlen, 107 snprintf(p, p_maxlen,
108 "puts() - %s\n", bio->method->name); 108 "puts() - %s\n", bio->method->name);
109 break; 109 break;
110 case BIO_CB_GETS: 110 case BIO_CB_GETS:
111 (void) snprintf(p, p_maxlen, "gets(%lu) - %s\n", 111 snprintf(p, p_maxlen, "gets(%lu) - %s\n",
112 (unsigned long)argi, bio->method->name); 112 (unsigned long)argi, bio->method->name);
113 break; 113 break;
114 case BIO_CB_CTRL: 114 case BIO_CB_CTRL:
115 (void) snprintf(p, p_maxlen, "ctrl(%lu) - %s\n", 115 snprintf(p, p_maxlen, "ctrl(%lu) - %s\n",
116 (unsigned long)argi, bio->method->name); 116 (unsigned long)argi, bio->method->name);
117 break; 117 break;
118 case BIO_CB_RETURN|BIO_CB_READ: 118 case BIO_CB_RETURN|BIO_CB_READ:
119 (void) snprintf(p, p_maxlen, "read return %ld\n", ret); 119 snprintf(p, p_maxlen, "read return %ld\n", ret);
120 break; 120 break;
121 case BIO_CB_RETURN|BIO_CB_WRITE: 121 case BIO_CB_RETURN|BIO_CB_WRITE:
122 (void) snprintf(p, p_maxlen, "write return %ld\n", ret); 122 snprintf(p, p_maxlen, "write return %ld\n", ret);
123 break; 123 break;
124 case BIO_CB_RETURN|BIO_CB_GETS: 124 case BIO_CB_RETURN|BIO_CB_GETS:
125 (void) snprintf(p, p_maxlen, "gets return %ld\n", ret); 125 snprintf(p, p_maxlen, "gets return %ld\n", ret);
126 break; 126 break;
127 case BIO_CB_RETURN|BIO_CB_PUTS: 127 case BIO_CB_RETURN|BIO_CB_PUTS:
128 (void) snprintf(p, p_maxlen, "puts return %ld\n", ret); 128 snprintf(p, p_maxlen, "puts return %ld\n", ret);
129 break; 129 break;
130 case BIO_CB_RETURN|BIO_CB_CTRL: 130 case BIO_CB_RETURN|BIO_CB_CTRL:
131 (void) snprintf(p, p_maxlen, "ctrl return %ld\n", ret); 131 snprintf(p, p_maxlen, "ctrl return %ld\n", ret);
132 break; 132 break;
133 default: 133 default:
134 (void) snprintf(p, p_maxlen, 134 snprintf(p, p_maxlen,
135 "bio callback - unknown type (%d)\n", cmd); 135 "bio callback - unknown type (%d)\n", cmd);
136 break; 136 break;
137 } 137 }