$Log$
+ Revision 580.66 2001/10/17 21:07:20 nbryant
+ further format string cleanups (for i686-linux type sizes)
+
Revision 580.65 2001/10/17 20:41:07 nbryant
- declare *printf format specifiers if gcc detected
- format string fixes (compiles w/o warnings on alpha osf/1)
Fri Jul 10 1998 Art Cancro <ajc@uncensored.citadel.org>
* Initial CVS import
+
}
cprintf(" ");
- cprintf("%ld ", length); /* bytes */
+ cprintf("%ld ", (long)length); /* bytes */
cprintf("NIL) "); /* lines */
}
}
if (is_literal) {
- cprintf("{%ld}\r\n%s", strlen(buf), buf);
+ cprintf("{%ld}\r\n%s", (long)strlen(buf), buf);
} else {
cprintf("\"%s\"", buf);
}
msg->cm_format_type = FMT_RFC822; /* internet message */
msg->cm_fields['M'] = rfc822;
- lprintf(9, "Unconverted RFC822 message length = %ld\n", strlen(rfc822));
+ lprintf(9, "Unconverted RFC822 message length = %ld\n", (long)strlen(rfc822));
pos = 0;
done = 0;
}
lprintf(9, "RFC822 length remaining after conversion = %ld\n",
- strlen(rfc822));
+ (long)strlen(rfc822));
return msg;
}
/* Truncate if the header told us to */
if ( (content_length > 0) && (length > content_length) ) {
length = content_length;
- lprintf(9, "truncated to %ld\n", content_length);
+ lprintf(9, "truncated to %ld\n", (long)content_length);
}
mime_decode(partnum,
{
cprintf("part=%s|%s|%s|%s|%s|%ld\n",
- name, filename, partnum, disp, cbtype, length);
+ name, filename, partnum, disp, cbtype, (long)length);
}
}
else if (strncasecmp(cbtype, "multipart/", 10)) {
cprintf("Part %s: %s (%s) (%ld bytes)\r\n",
- partnum, filename, cbtype, length);
+ partnum, filename, cbtype, (long)length);
}
}
return;
}
- cprintf("%d %ld\n", BINARY_FOLLOWS, smr.len);
+ cprintf("%d %ld\n", BINARY_FOLLOWS, (long)smr.len);
client_write(smr.ser, smr.len);
phree(smr.ser);
}
ret->len = ret->len +
strlen(msg->cm_fields[(int)forder[i]]) + 2;
- lprintf(9, "serialize_message() calling malloc(%ld)\n", ret->len);
+ lprintf(9, "serialize_message() calling malloc(%ld)\n", (long)ret->len);
ret->ser = mallok(ret->len);
if (ret->ser == NULL) {
ret->len = 0;
wlen = wlen + strlen(msg->cm_fields[(int)forder[i]]) + 1;
}
if (ret->len != wlen) lprintf(3, "ERROR: len=%ld wlen=%ld\n",
- ret->len, wlen);
+ (long)ret->len, (long)wlen);
return;
}
} else {
buffer_len = (buffer_len * 2);
m = ptr;
- lprintf(9, "buffer_len is %ld\n", buffer_len);
+ lprintf(9, "buffer_len is %ld\n", (long)buffer_len);
}
}
}
sprintf(buf,"./bio/%ld",ruser.usernum);
- cprintf("%d OK|%s|%ld|%d|%d|%ld|%ld\n", LISTING_FOLLOWS,
+ cprintf("%d OK|%s|%ld|%d|%ld|%ld|%ld\n", LISTING_FOLLOWS,
ruser.fullname, ruser.usernum, ruser.axlevel,
- ruser.lastcall, ruser.timescalled, ruser.posted);
+ (long)ruser.lastcall, ruser.timescalled, ruser.posted);
fp = fopen(buf,"r");
if (fp == NULL)
cprintf("%s has no bio on file.\n", ruser.fullname);
instr = mallok(instr_len);
if (instr == NULL) {
lprintf(1, "Cannot allocate %ld bytes for instr...\n",
- instr_len);
+ (long)instr_len);
abort();
}
sprintf(instr,
if (strlen(pw) != (MD5_HEXSTRING_SIZE-1))
{
- cprintf("%d Auth string of length %ld is the wrong length (should be %d).\n", ERROR, strlen(pw), MD5_HEXSTRING_SIZE-1);
+ cprintf("%d Auth string of length %ld is the wrong length (should be %d).\n", ERROR, (long)strlen(pw), MD5_HEXSTRING_SIZE-1);
return;
}
else {
cprintf("+OK %d %ld\r\n",
which_one,
- POP3->msgs[which_one-1].rfc822_length
+ (long)POP3->msgs[which_one-1].rfc822_length
);
return;
}
if (! POP3->msgs[i].deleted) {
cprintf("%d %ld\r\n",
i+1,
- POP3->msgs[i].rfc822_length);
+ (long)POP3->msgs[i].rfc822_length);
}
}
cprintf(".\r\n");
}
}
- cprintf("+OK %d %ld\r\n", total_msgs, total_octets);
+ cprintf("+OK %d %ld\r\n", total_msgs, (long)total_octets);
}
if ((CC->usersupp.axlevel >= 6)
|| ((usbuf->flags & US_UNLISTED) == 0)
|| ((CC->internal_pgm))) {
- cprintf("%s|%d|%ld|%d|%ld|%ld|",
+ cprintf("%s|%d|%ld|%ld|%ld|%ld|",
usbuf->fullname,
usbuf->axlevel,
usbuf->usernum,
- usbuf->lastcall,
+ (long)usbuf->lastcall,
usbuf->timescalled,
usbuf->posted);
if (CC->usersupp.axlevel >= 6)
cprintf("%d No such user.\n", ERROR + NO_SUCH_USER);
return;
}
- cprintf("%d %s|%s|%u|%ld|%ld|%d|%ld|%d|%d\n",
+ cprintf("%d %s|%s|%u|%ld|%ld|%d|%ld|%ld|%d\n",
OK,
usbuf.fullname,
usbuf.password,
usbuf.posted,
(int) usbuf.axlevel,
usbuf.usernum,
- usbuf.lastcall,
+ (long)usbuf.lastcall,
usbuf.USuserpurge);
}