grpc_udp_server_write method

pull/2376/head
Robbie Shade 10 years ago
parent 4b70e03d00
commit 4cde25cd01
  1. 9
      src/core/iomgr/udp_server.c
  2. 2
      test/core/iomgr/udp_server_test.c

@ -382,17 +382,14 @@ void grpc_udp_server_start(grpc_udp_server *s, grpc_pollset **pollsets,
fprintf(stderr, "grpc_udp_server_start Started UDP server\n");
}
/*
void grpc_udp_server_write(server_port *sp,
const char *buffer,
size_t buf_len,
const struct sockaddr* peer_address) {
/* TODO(rjshade): Add a test for this method. */
void grpc_udp_server_write(server_port *sp, const char *buffer, size_t buf_len,
const struct sockaddr *peer_address) {
int rc;
rc = sendto(sp->fd, buffer, buf_len, 0, peer_address, sizeof(peer_address));
if (rc < 0) {
gpr_log(GPR_ERROR, "Unable to send data: %s", strerror(errno));
}
}
*/
#endif

@ -48,7 +48,7 @@
static grpc_pollset g_pollset;
static int g_number_of_reads = 0;
static void on_connect(void *arg, grpc_endpoint *tcp) {
static void on_connect(void *arg, grpc_endpoint *udp) {
}
static void on_read(int fd, grpc_udp_server_cb new_transport_cb, void *cb_arg) {

Loading…
Cancel
Save