 diff --git a/gmetad/conf.c.in b/gmetad/conf.c.in
-index 095d000..24bba2c 100644
+index 8ed3cfd..886a091 100644
 --- a/gmetad/conf.c.in
 +++ b/gmetad/conf.c.in
 @@ -77,12 +77,13 @@ static DOTCONF_CB(cb_data_source)

 
    key.data = cmd->data.list[0];
diff --git a/gmetad/data_thread.c b/gmetad/data_thread.c
index e5707d7..ab54e14 100644
--- a/gmetad/data_thread.c
+++ b/gmetad/data_thread.c
@@ -68,7 +68,7 @@ data_thread ( void *arg )
          
          /* If we successfully read from a good data source last time then try the same host again first. */

+  return s;
+}
+
 #endif /* WITH_RIEMANN */
 
 void init_sockaddr (struct sockaddr_in *name, const char *hostname, uint16_t port)
@@ -494,8 +545,8 @@ send_data_to_riemann (const char *grid, const char *cluster, const char *host, c
             evt.time, evt.host, evt.service, evt.state, evt.metric_f, evt.metric_d, evt.metric_sint64, evt.description, evt.ttl, evt.n_tags, evt.n_attributes);
 
   int nbytes;
-  nbytes = sendto (riemann_udp_socket->sockfd, buf, len, 0,
-                         (struct sockaddr_in*)&riemann_udp_socket->sa, sizeof (struct sockaddr_in));
+  
+  nbytes = send(riemann_udp_socket->sockfd, buf, len, 0);
 
   if (nbytes != len)
   {
diff --git a/gmetad/export_helpers.h b/gmetad/export_helpers.h
index bcf7ee4..ede4cbe 100644
--- a/gmetad/export_helpers.h
+++ b/gmetad/export_helpers.h
@@ -28,6 +28,13 @@ write_data_to_carbon ( const char *source, const char *host, const char *metric,
 g_udp_socket*
 init_riemann_udp_socket (const char *hostname, uint16_t port);
 
+g_udp_socket*
+init_riemann_udp6_socket (const char *hostname, uint16_t port);
+
+g_tcp_socket*
+init_riemann_tcp6_socket (const char *hostname, uint16_t port);
+
+
 int                                              /* Ganglia   =>  Riemann */
 send_data_to_riemann (const char *grid,          /* grid      =>  grid */
                       const char *cluster,       /* cluster   =>  cluster */
diff --git a/gmetad/gmetad.c b/gmetad/gmetad.c
index ebf704a..d42736a 100644
--- a/gmetad/gmetad.c
+++ b/gmetad/gmetad.c
@@ -58,7 +58,7 @@ print_sources ( datum_t *key, datum_t *val, void *arg )
 {
    int i;
    data_source_list_t *d = *((data_source_list_t **)(val->data));
