[beast/devel: 4/26] SFI: use memmove(), since g_memmove() was removed from GLib



commit 437cf680f4e4bb8d1ea608337df328517e738a75
Author: Tim Janik <timj gnu org>
Date:   Sat Oct 11 05:26:38 2014 +0200

    SFI: use memmove(), since g_memmove() was removed from GLib

 sfi/gbsearcharray.hh |    4 ++--
 sfi/sficomport.cc    |    2 +-
 sfi/sficomwire.cc    |    6 +++---
 3 files changed, 6 insertions(+), 6 deletions(-)
---
diff --git a/sfi/gbsearcharray.hh b/sfi/gbsearcharray.hh
index 84b3601..d33a713 100644
--- a/sfi/gbsearcharray.hh
+++ b/sfi/gbsearcharray.hh
@@ -199,7 +199,7 @@ g_bsearch_array_grow (GBSearchArray        *barray,
   else
     barray = (GBSearchArray *) g_realloc (barray, sizeof (GBSearchArray) + new_size);
   node = G_BSEARCH_ARRAY_NODES (barray) + index * bconfig->sizeof_node;
-  g_memmove (node + bconfig->sizeof_node, node, (barray->n_nodes - index) * bconfig->sizeof_node);
+  memmove (node + bconfig->sizeof_node, node, (barray->n_nodes - index) * bconfig->sizeof_node);
   barray->n_nodes += 1;
   return barray;
 }
@@ -255,7 +255,7 @@ g_bsearch_array_remove (GBSearchArray        *barray,
 
   barray->n_nodes -= 1;
   node = G_BSEARCH_ARRAY_NODES (barray) + index * bconfig->sizeof_node;
-  g_memmove (node, node + bconfig->sizeof_node, (barray->n_nodes - index) * bconfig->sizeof_node);
+  memmove (node, node + bconfig->sizeof_node, (barray->n_nodes - index) * bconfig->sizeof_node);
   if (G_UNLIKELY (bconfig->flags & G_BSEARCH_ARRAY_AUTO_SHRINK))
     {
       guint new_size = barray->n_nodes * bconfig->sizeof_node;
diff --git a/sfi/sficomport.cc b/sfi/sficomport.cc
index a6064dd..9fb0d94 100644
--- a/sfi/sficomport.cc
+++ b/sfi/sficomport.cc
@@ -304,7 +304,7 @@ com_port_write_queued (SfiComPort *port)
       if (n > 0)
        {
          port->wbuffer.n -= n;
-         g_memmove (port->wbuffer.data, port->wbuffer.data + n, port->wbuffer.n);
+         memmove (port->wbuffer.data, port->wbuffer.data + n, port->wbuffer.n);
        }
     }
   return TRUE; /* connection remains valid */
diff --git a/sfi/sficomwire.cc b/sfi/sficomwire.cc
index 5e359d3..f0b74ad 100644
--- a/sfi/sficomwire.cc
+++ b/sfi/sficomwire.cc
@@ -136,7 +136,7 @@ wire_write_remote (SfiComWire *wire)
        wire->remote_output_broke = TRUE;
 
       n = wire->obp - buf;
-      g_memmove (wire->obuffer, buf, n);
+      memmove (wire->obuffer, buf, n);
       wire->obp = wire->obuffer + n;
     }
 }
@@ -276,7 +276,7 @@ wire_receive (SfiComWire *wire)
                    }
                }
              n = wire->ibp - p;
-             g_memmove (wire->ibuffer, p, n);
+             memmove (wire->ibuffer, p, n);
              wire->ibp = wire->ibuffer + n;
              break;
            case SFI_COM_MSG_RESERVED1:
@@ -288,7 +288,7 @@ wire_receive (SfiComWire *wire)
              p += 4;   /* request */
              p += strl;
              n = wire->ibp - p;
-             g_memmove (wire->ibuffer, p, n);
+             memmove (wire->ibuffer, p, n);
              wire->ibp = wire->ibuffer + n;
              break;
            default:


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]