line = strdup(value);
if (strrchr(line, '"')) {
*strrchr(line, '"') = '\0';
line = strdup(value);
if (strrchr(line, '"')) {
*strrchr(line, '"') = '\0';
- silc_silc_snprintf(b, sizeof(b) - 1, "--%s", line + 1);
+ silc_snprintf(b, sizeof(b) - 1, "--%s", line + 1);
- silc_silc_snprintf(b, sizeof(b) - 1, "--%s", line);
+ silc_snprintf(b, sizeof(b) - 1, "--%s", line);
while (silc_hash_table_get(&htl, (void **)&field, (void **)&value)) {
memset(tmp, 0, sizeof(tmp));
SILC_LOG_DEBUG(("Header %s: %s", field, value));
while (silc_hash_table_get(&htl, (void **)&field, (void **)&value)) {
memset(tmp, 0, sizeof(tmp));
SILC_LOG_DEBUG(("Header %s: %s", field, value));
- silc_silc_snprintf(tmp, sizeof(tmp) - 1, "%s: %s\r\n", field, value);
+ silc_snprintf(tmp, sizeof(tmp) - 1, "%s: %s\r\n", field, value);
/* If fields are not present, add extra CRLF */
if (!silc_hash_table_count(part->fields))
/* If fields are not present, add extra CRLF */
if (!silc_hash_table_count(part->fields))
- silc_silc_snprintf(tmp2, sizeof(tmp2) - 1, "\r\n");
- silc_silc_snprintf(tmp, sizeof(tmp) - 1, "%s--%s\r\n%s",
+ silc_snprintf(tmp2, sizeof(tmp2) - 1, "\r\n");
+ silc_snprintf(tmp, sizeof(tmp) - 1, "%s--%s\r\n%s",
- silc_silc_snprintf(tmp, sizeof(tmp) - 1, "\r\n--%s--\r\n", mime->boundary);
+ silc_snprintf(tmp, sizeof(tmp) - 1, "\r\n--%s--\r\n", mime->boundary);
memset(type, 0, sizeof(type));
gethostname(type, sizeof(type) - 1);
srand((time(NULL) + buf_len) ^ rand());
memset(type, 0, sizeof(type));
gethostname(type, sizeof(type) - 1);
srand((time(NULL) + buf_len) ^ rand());
- silc_silc_snprintf(id, sizeof(id) - 1, "%X%X%X%s",
+ silc_snprintf(id, sizeof(id) - 1, "%X%X%X%s",
(unsigned int)rand(), (unsigned int)time(NULL),
(unsigned int)buf_len, type);
(unsigned int)rand(), (unsigned int)time(NULL),
(unsigned int)buf_len, type);
silc_mime_add_field(partial, "MIME-Version", "1.0");
memset(type, 0, sizeof(type));
silc_mime_add_field(partial, "MIME-Version", "1.0");
memset(type, 0, sizeof(type));
"message/partial; id=\"%s\"; number=1", id);
silc_mime_add_field(partial, "Content-Type", type);
silc_mime_add_data(partial, buf, max_size);
"message/partial; id=\"%s\"; number=1", id);
silc_mime_add_field(partial, "Content-Type", type);
silc_mime_add_data(partial, buf, max_size);
"message/partial; id=\"%s\"; number=%d",
id, num++);
silc_mime_add_data(partial, buf + off, max_size);
off += max_size;
len -= max_size;
} else {
"message/partial; id=\"%s\"; number=%d",
id, num++);
silc_mime_add_data(partial, buf + off, max_size);
off += max_size;
len -= max_size;
} else {
"message/partial; id=\"%s\"; number=%d; total=%d",
id, num, num);
silc_mime_add_data(partial, buf + off, len);
"message/partial; id=\"%s\"; number=%d; total=%d",
id, num, num);
silc_mime_add_data(partial, buf + off, len);
- silc_silc_snprintf(tmp, sizeof(tmp) - 1, "multipart/%s; boundary=%s", type, boundary);
+ silc_snprintf(tmp, sizeof(tmp) - 1, "multipart/%s; boundary=%s", type, boundary);
silc_mime_add_field(mime, "Content-Type", tmp);
silc_free(mime->boundary);
mime->boundary = strdup(boundary);
silc_mime_add_field(mime, "Content-Type", tmp);
silc_free(mime->boundary);
mime->boundary = strdup(boundary);