]> andersk Git - openssh.git/blobdiff - buffer.c
- Prevent typedefs from being compiled more than once. Report from
[openssh.git] / buffer.c
index 4cab175bb161313e251f0e8da9284a9221ec86e4..2164dcb1242ea642c963b94dc648ab6ac0c290b1 100644 (file)
--- a/buffer.c
+++ b/buffer.c
@@ -40,8 +40,10 @@ buffer_free(Buffer *buffer)
        xfree(buffer->buf);
 }
 
-/* Clears any data from the buffer, making it empty.  This does not actually
-   zero the memory. */
+/*
+ * Clears any data from the buffer, making it empty.  This does not actually
+ * zero the memory.
+ */
 
 void 
 buffer_clear(Buffer *buffer)
@@ -60,9 +62,11 @@ buffer_append(Buffer *buffer, const char *data, unsigned int len)
        memcpy(cp, data, len);
 }
 
-/* Appends space to the buffer, expanding the buffer if necessary.
-   This does not actually copy the data into the buffer, but instead
-   returns a pointer to the allocated region. */
+/*
+ * Appends space to the buffer, expanding the buffer if necessary. This does
+ * not actually copy the data into the buffer, but instead returns a pointer
+ * to the allocated region.
+ */
 
 void 
 buffer_append_space(Buffer *buffer, char **datap, unsigned int len)
@@ -79,8 +83,10 @@ restart:
                buffer->end += len;
                return;
        }
-       /* If the buffer is quite empty, but all data is at the end, move
-          the data to the beginning and retry. */
+       /*
+        * If the buffer is quite empty, but all data is at the end, move the
+        * data to the beginning and retry.
+        */
        if (buffer->offset > buffer->alloc / 2) {
                memmove(buffer->buf, buffer->buf + buffer->offset,
                        buffer->end - buffer->offset);
This page took 0.09873 seconds and 4 git commands to generate.