projects
/
paraslash.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
command.c: cast members of struct timeval to long unsigned
[paraslash.git]
/
recv.c
diff --git
a/recv.c
b/recv.c
index 13c5c420d35059d80fa25ba4e6c9cb73551f9b06..95711f1fce1c4ea56f8bbe00ff829d5a8bbc401c 100644
(file)
--- a/
recv.c
+++ b/
recv.c
@@
-19,13
+19,14
@@
#include "recv.h"
#include "recv.cmdline.h"
#include "recv.h"
#include "recv.cmdline.h"
+#include "fd.h"
#include "error.h"
struct gengetopt_args_info conf;
INIT_RECV_ERRLISTS;
#include "error.h"
struct gengetopt_args_info conf;
INIT_RECV_ERRLISTS;
-__printf_2_3 void para_log(int ll, char* fmt,...)
+__printf_2_3 void para_log(int ll, c
onst c
har* fmt,...)
{
va_list argp;
{
va_list argp;
@@
-84,13
+85,11
@@
recv:
timeout.tv_usec = 1000 * 1000;
max = -1;
ret = r->pre_select(&rn, &rfds, &wfds, &timeout);
timeout.tv_usec = 1000 * 1000;
max = -1;
ret = r->pre_select(&rn, &rfds, &wfds, &timeout);
- max = MAX(max, ret);
+ max =
PARA_
MAX(max, ret);
PARA_DEBUG_LOG("timeout: %lums\n", tv2ms(&timeout));
PARA_DEBUG_LOG("timeout: %lums\n", tv2ms(&timeout));
- ret =
select(max + 1, &rfds, &wfds, NULL
, &timeout);
+ ret =
para_select(max + 1, &rfds, &wfds
, &timeout);
if (ret < 0) {
if (ret < 0) {
- if (errno == EINTR || errno == EAGAIN)
- goto recv;
ret = -E_RECV_SELECT;
goto out;
}
ret = -E_RECV_SELECT;
goto out;
}