Browse code

tsend: s/char*/const char*/ in function params.

Andrei Pelinescu-Onciul authored on 23/06/2010 21:13:23
Showing 2 changed files
... ...
@@ -120,7 +120,7 @@ poll_loop: \
120 120
  *  (if less than len => couldn't send all)
121 121
  *  bugs: signals will reset the timer
122 122
  */
123
-int tsend_stream(int fd, char* buf, unsigned int len, int timeout)
123
+int tsend_stream(int fd, const char* buf, unsigned int len, int timeout)
124 124
 {
125 125
 	int written;
126 126
 	TSEND_INIT;
... ...
@@ -157,7 +157,7 @@ error:
157 157
  *  (if less than len => couldn't send all)
158 158
  *  bugs: signals will reset the timer
159 159
  */
160
-int tsend_dgram(int fd, char* buf, unsigned int len, 
160
+int tsend_dgram(int fd, const char* buf, unsigned int len, 
161 161
 				const struct sockaddr* to, socklen_t tolen, int timeout)
162 162
 {
163 163
 	TSEND_INIT;
... ...
@@ -34,8 +34,8 @@
34 34
 #define __tsend_h
35 35
 
36 36
 
37
-int tsend_stream(int fd, char* buf, unsigned int len, int timeout);
38
-int tsend_dgram(int fd, char* buf, unsigned int len, 
37
+int tsend_stream(int fd, const char* buf, unsigned int len, int timeout);
38
+int tsend_dgram(int fd, const char* buf, unsigned int len, 
39 39
 				const struct sockaddr* to, socklen_t tolen, int timeout);
40 40
 int tsend_dgram_ev(int fd, const struct iovec* v, int count, int timeout);
41 41