Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
a few casts to help compilation with gcc-4.0
authoralegrand <alegrand@48e7efb5-ca39-0410-a469-dd3cf9ba447f>
Wed, 21 Sep 2005 10:43:35 +0000 (10:43 +0000)
committeralegrand <alegrand@48e7efb5-ca39-0410-a469-dd3cf9ba447f>
Wed, 21 Sep 2005 10:43:35 +0000 (10:43 +0000)
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/simgrid/simgrid/trunk@1727 48e7efb5-ca39-0410-a469-dd3cf9ba447f

src/gras/DataDesc/ddt_exchange.c
src/gras/Transport/transport_plugin_tcp.c

index 36af95d..7867ef5 100644 (file)
@@ -473,7 +473,7 @@ gras_datadesc_send_rec(gras_socket_t         sock,
     sub_type = ref_data.type;
     if (sub_type == NULL) {
       sub_type = (*ref_data.selector)(type,state,data);
     sub_type = ref_data.type;
     if (sub_type == NULL) {
       sub_type = (*ref_data.selector)(type,state,data);
-      gras_dd_send_int(sock, &(sub_type->code),1 /*stable*/);
+      gras_dd_send_int(sock, (int*) &(sub_type->code),1 /*stable*/);
     }
     
     /* Send the actual value of the pointer for cycle handling */
     }
     
     /* Send the actual value of the pointer for cycle handling */
index 227a443..ca4b880 100644 (file)
@@ -292,7 +292,7 @@ gras_trp_tcp_recv_withbuffer(gras_socket_t sock,
     
     DEBUG5("read(%d, %p, %ld) got %d so far (%s)",
          sock->sd, data+got, bufsize, got,
     
     DEBUG5("read(%d, %p, %ld) got %d so far (%s)",
          sock->sd, data+got, bufsize, got,
-         hexa_str(data,got));
+         hexa_str((unsigned char*)data,got));
     status = tcp_read(sock->sd, data+got, (size_t)bufsize);
     
     if (status < 0) {
     status = tcp_read(sock->sd, data+got, (size_t)bufsize);
     
     if (status < 0) {
@@ -300,7 +300,7 @@ gras_trp_tcp_recv_withbuffer(gras_socket_t sock,
             sock->sd, data+got, (int)size,
             sock_errstr);
     }
             sock->sd, data+got, (int)size,
             sock_errstr);
     }
-    DEBUG2("Got %d more bytes (%s)",status,hexa_str(data+got,status));
+    DEBUG2("Got %d more bytes (%s)",status,hexa_str((unsigned char*)data+got,status));
     
     if (status) {
       bufsize -= status;
     
     if (status) {
       bufsize -= status;
@@ -391,14 +391,14 @@ gras_trp_buf_send(gras_socket_t sock,
           (int)data->out_buf.size,
           ((int)data->out_buf.size) + thissize -1,
           size,
           (int)data->out_buf.size,
           ((int)data->out_buf.size) + thissize -1,
           size,
-          hexa_str((char*)chunk,thissize));
+          hexa_str((unsigned char*)chunk,thissize));
 
     memcpy(data->out_buf.data + data->out_buf.size, chunk + chunk_pos, thissize);
 
     data->out_buf.size += thissize;
     chunk_pos      += thissize;
     DEBUG4("New pos = %d; Still to send = %ld of %ld; ctn sofar=(%s)",
 
     memcpy(data->out_buf.data + data->out_buf.size, chunk + chunk_pos, thissize);
 
     data->out_buf.size += thissize;
     chunk_pos      += thissize;
     DEBUG4("New pos = %d; Still to send = %ld of %ld; ctn sofar=(%s)",
-          data->out_buf.size,size-chunk_pos,size,hexa_str((char*)chunk,chunk_pos));
+          data->out_buf.size,size-chunk_pos,size,hexa_str((unsigned char*)chunk,chunk_pos));
 
     if (data->out_buf.size == data->buffsize) /* out of space. Flush it */
       gras_trp_bufiov_flush(sock);
 
     if (data->out_buf.size == data->buffsize) /* out of space. Flush it */
       gras_trp_bufiov_flush(sock);
@@ -442,7 +442,7 @@ gras_trp_buf_recv(gras_socket_t sock,
     data->in_buf.pos += thissize;
     chunk_pos        += thissize;
     DEBUG4("New pos = %d; Still to receive = %ld of %ld. Ctn so far=(%s)",
     data->in_buf.pos += thissize;
     chunk_pos        += thissize;
     DEBUG4("New pos = %d; Still to receive = %ld of %ld. Ctn so far=(%s)",
-          data->in_buf.pos,size - chunk_pos,size,hexa_str(chunk,chunk_pos));
+          data->in_buf.pos,size - chunk_pos,size,hexa_str((unsigned char*)chunk,chunk_pos));
   }
 
   XBT_OUT;
   }
 
   XBT_OUT;