]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
comm_write() should operate on a const char *buf, not a char *buf
authoradrian <>
Wed, 23 Oct 2002 15:17:34 +0000 (15:17 +0000)
committeradrian <>
Wed, 23 Oct 2002 15:17:34 +0000 (15:17 +0000)
src/comm.cc
src/comm.h

index 5d9922f078c3f90090dd0b593c025be4a9eeffd2..0ce58c179bcc68e77d6ccdc68f5a28dc5d769e9f 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: comm.cc,v 1.348 2002/10/21 15:13:23 adrian Exp $
+ * $Id: comm.cc,v 1.349 2002/10/23 09:17:34 adrian Exp $
  *
  * DEBUG: section 5     Socket Functions
  * AUTHOR: Harvest Derived
@@ -87,7 +87,7 @@ struct _fdc_t {
                void *handler_data;
        } read;
        struct {
-               char *buf;
+               const char *buf;
                int size;
                int curofs;
                IOCB *handler;
@@ -665,7 +665,7 @@ comm_write_try(int fd, void *data)
  * completes, on error, or on file descriptor close.
  */
 void
-comm_write(int fd, char *buf, size_t size, IOWCB *handler, void *handler_data)
+comm_write(int fd, const char *buf, size_t size, IOWCB *handler, void *handler_data)
 {
        /* Make sure we're not writing anything and we're not closing */
        assert(fdc_table[fd].active == 1);
index c8204dad37eca8ad7db4af4bcec7928f5cbb45db..10caea20c495f87033a6eecdc4b34b48ba3ddc33 100644 (file)
@@ -17,6 +17,6 @@ extern int comm_udp_recvfrom(int fd, void *buf, size_t len, int flags,
 extern int comm_udp_recv(int fd, void *buf, size_t len, int flags);
 extern ssize_t comm_udp_send(int s, const void *buf, size_t len, int flags);
 
-extern void comm_write(int s, char *buf, size_t len, IOWCB *callback, void *callback_data);
+extern void comm_write(int s, const char *buf, size_t len, IOWCB *callback, void *callback_data);
 
 #endif