even when io_timeout is a longer value (though the code in options.c
might set it to a shorter value if io_timeout is small).
extern int am_server;
extern int am_daemon;
extern int am_sender;
extern int am_server;
extern int am_daemon;
extern int am_sender;
+extern int eol_nulls;
+extern char *remote_filesfrom_file;
extern struct stats stats;
extern struct stats stats;
const char phase_unknown[] = "unknown";
const char phase_unknown[] = "unknown";
+int select_timeout = SELECT_TIMEOUT;
/**
* The connection might be dropped at some point; perhaps because the
/**
* The connection might be dropped at some point; perhaps because the
return 0;
FD_ZERO(&fds);
FD_SET(msg_fd_out, &fds);
return 0;
FD_ZERO(&fds);
FD_SET(msg_fd_out, &fds);
- tv.tv_sec = io_timeout ? io_timeout : SELECT_TIMEOUT;
+ tv.tv_sec = select_timeout;
tv.tv_usec = 0;
if (!select(msg_fd_out+1, NULL, &fds, NULL, &tv))
check_timeout();
tv.tv_usec = 0;
if (!select(msg_fd_out+1, NULL, &fds, NULL, &tv))
check_timeout();
- tv.tv_sec = io_timeout?io_timeout:SELECT_TIMEOUT;
+ tv.tv_sec = select_timeout;
tv.tv_usec = 0;
errno = 0;
tv.tv_usec = 0;
errno = 0;
io_filesfrom_buflen = io_filesfrom_lastchar? 2 : 1;
io_filesfrom_f_in = -1;
} else {
io_filesfrom_buflen = io_filesfrom_lastchar? 2 : 1;
io_filesfrom_f_in = -1;
} else {
if (!eol_nulls) {
char *s = io_filesfrom_buf + l;
/* Transform CR and/or LF into '\0' */
if (!eol_nulls) {
char *s = io_filesfrom_buf + l;
/* Transform CR and/or LF into '\0' */
{
char ch, *s, *eob = fname + MAXPATHLEN - 1;
int cnt;
{
char ch, *s, *eob = fname + MAXPATHLEN - 1;
int cnt;
- extern int io_timeout;
- extern int eol_nulls;
- extern char *remote_filesfrom_file;
int reading_remotely = remote_filesfrom_file != NULL;
int nulls = eol_nulls || reading_remotely;
int reading_remotely = remote_filesfrom_file != NULL;
int nulls = eol_nulls || reading_remotely;
fd_set fds;
FD_ZERO(&fds);
FD_SET(fd, &fds);
fd_set fds;
FD_ZERO(&fds);
FD_SET(fd, &fds);
- tv.tv_sec = io_timeout? io_timeout : SELECT_TIMEOUT;
+ tv.tv_sec = select_timeout;
tv.tv_usec = 0;
if (!select(fd+1, &fds, NULL, NULL, &tv))
check_timeout();
tv.tv_usec = 0;
if (!select(fd+1, &fds, NULL, NULL, &tv))
check_timeout();
- tv.tv_sec = io_timeout?io_timeout:SELECT_TIMEOUT;
+ tv.tv_sec = select_timeout;
tv.tv_usec = 0;
errno = 0;
tv.tv_usec = 0;
errno = 0;