$Log$
+ Revision 626.8 2004/10/06 21:23:21 error
+ * Fixup a few more compiler warnings from icc
+
Revision 626.7 2004/10/05 01:44:20 ajc
* Changed a bunch of localtime() calls to localtime_r(), for great justice.
Fri Jul 10 1998 Art Cancro <ajc@uncensored.citadel.org>
* Initial CVS import
+
if (!buf) return 0;
if (!cret) return 0;
if (bytes < 1) return 0;
- if (offset < 0) return 0;
CtdlIPC_lock(ipc);
sprintf(aaa, "READ %d|%d", (int)offset, (int)bytes);
*buf = (void *)realloc(*buf, (size_t)(offset + len));
if (*buf) {
/* I know what I'm doing */
- serv_read(ipc, (*buf + offset), len);
+ serv_read(ipc, ((char *)(*buf) + offset), len);
} else {
/* We have to read regardless */
serv_read(ipc, aaa, len);
else {
len = extract_long(&aaa[4], 0);
/* I know what I'm doing */
- serv_read(ipc, ((*buf) + (i * 4096)), len);
+ serv_read(ipc, ((char *)(*buf) + (i * 4096)), len);
}
if (progress_gauge_callback)
progress_gauge_callback(ipc, i * 4096 + len, bytes);
char description[80]; /* Description on server */
FILE *local_fd; /* Open file on client */
size_t size; /* Size of file in octets */
- int upload:1; /* uploading? 0 if downloading */
- int complete:1; /* Transfer has finished? */
+ unsigned int upload:1; /* uploading? 0 if downloading */
+ unsigned int complete:1; /* Transfer has finished? */
};
*/
void begin_session(struct CitContext *con)
{
- int len; /* should be socklen_t but doesn't work on Macintosh */
+ int len;
struct sockaddr_in sin;
/*
len = sizeof sin;
if (!CC->is_local_socket) {
if (!getpeername(con->client_socket,
- (struct sockaddr *) &sin, &len))
+ (struct sockaddr *) &sin, &len)) /* should be socklen_t but doesn't work on Macintosh */
locate_host(con->cs_host, sizeof con->cs_host,
con->cs_addr, sizeof con->cs_addr,
&sin.sin_addr);