aboutsummaryrefslogtreecommitdiff
path: root/src/vpn/gnunet-helper-vpn.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2010-12-21 14:07:53 +0000
committerChristian Grothoff <christian@grothoff.org>2010-12-21 14:07:53 +0000
commitc9821c80f60d980cbf8f973f78eed6094270a653 (patch)
tree32331eae5ea335cd84952ecbdfb9b8ebdb7b433d /src/vpn/gnunet-helper-vpn.c
parentc802e7d908d82fd18833de63a417a55c69b5acd7 (diff)
downloadgnunet-c9821c80f60d980cbf8f973f78eed6094270a653.tar.gz
gnunet-c9821c80f60d980cbf8f973f78eed6094270a653.zip
avoid %m
Diffstat (limited to 'src/vpn/gnunet-helper-vpn.c')
-rw-r--r--src/vpn/gnunet-helper-vpn.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/vpn/gnunet-helper-vpn.c b/src/vpn/gnunet-helper-vpn.c
index 4a367e9c9..b8b5b16e6 100644
--- a/src/vpn/gnunet-helper-vpn.c
+++ b/src/vpn/gnunet-helper-vpn.c
@@ -215,7 +215,7 @@ outer:
215 struct suid_packet *pkt = (struct suid_packet*) buf; 215 struct suid_packet *pkt = (struct suid_packet*) buf;
216 r = read(0, buf, sizeof(struct GNUNET_MessageHeader)); 216 r = read(0, buf, sizeof(struct GNUNET_MessageHeader));
217 if (r <= 0) { 217 if (r <= 0) {
218 fprintf(stderr, "read-error: %m\n"); 218 fprintf(stderr, "read-error: %s\n", strerror (errno));
219 shutdown(fd_tun, SHUT_WR); 219 shutdown(fd_tun, SHUT_WR);
220 shutdown(0, SHUT_RD); 220 shutdown(0, SHUT_RD);
221 wri=0; 221 wri=0;
@@ -225,7 +225,7 @@ outer:
225 while (r < ntohs(pkt->hdr.size)) { 225 while (r < ntohs(pkt->hdr.size)) {
226 int t = read(0, buf + r, ntohs(pkt->hdr.size) - r); 226 int t = read(0, buf + r, ntohs(pkt->hdr.size) - r);
227 if (r < 0) { 227 if (r < 0) {
228 fprintf(stderr, "read-error: %m\n"); 228 fprintf(stderr, "read-error: %s\n", strerror (errno));
229 shutdown(fd_tun, SHUT_WR); 229 shutdown(fd_tun, SHUT_WR);
230 shutdown(0, SHUT_RD); 230 shutdown(0, SHUT_RD);
231 wri=0; 231 wri=0;
@@ -237,7 +237,7 @@ outer:
237 while (r < ntohs(pkt->hdr.size) - sizeof(struct GNUNET_MessageHeader)) { 237 while (r < ntohs(pkt->hdr.size) - sizeof(struct GNUNET_MessageHeader)) {
238 int t = write(fd_tun, pkt->data, ntohs(pkt->hdr.size) - sizeof(struct GNUNET_MessageHeader) - r); 238 int t = write(fd_tun, pkt->data, ntohs(pkt->hdr.size) - sizeof(struct GNUNET_MessageHeader) - r);
239 if (t < 0) { 239 if (t < 0) {
240 fprintf(stderr, "write-error 3: %m\n"); 240 fprintf(stderr, "write-error 3: %s\n", strerror (errno));
241 shutdown(fd_tun, SHUT_WR); 241 shutdown(fd_tun, SHUT_WR);
242 shutdown(0, SHUT_RD); 242 shutdown(0, SHUT_RD);
243 wri = 0; 243 wri = 0;
@@ -249,7 +249,7 @@ outer:
249 write_stdout_possible = 0; 249 write_stdout_possible = 0;
250 r = read(fd_tun, buf, MAX_SIZE); 250 r = read(fd_tun, buf, MAX_SIZE);
251 if (r <= 0) { 251 if (r <= 0) {
252 fprintf(stderr, "read-error: %m\n"); 252 fprintf(stderr, "read-error: %s\n", strerror (errno));
253 shutdown(fd_tun, SHUT_RD); 253 shutdown(fd_tun, SHUT_RD);
254 shutdown(1, SHUT_WR); 254 shutdown(1, SHUT_WR);
255 rea = 0; 255 rea = 0;
@@ -260,7 +260,7 @@ outer:
260 while(r < sizeof(struct GNUNET_MessageHeader)) { 260 while(r < sizeof(struct GNUNET_MessageHeader)) {
261 int t = write(1, &hdr, sizeof(struct GNUNET_MessageHeader) - r); 261 int t = write(1, &hdr, sizeof(struct GNUNET_MessageHeader) - r);
262 if (t < 0) { 262 if (t < 0) {
263 fprintf(stderr, "write-error 2: %m\n"); 263 fprintf(stderr, "write-error 2: %s\n", strerror (errno));
264 shutdown(fd_tun, SHUT_RD); 264 shutdown(fd_tun, SHUT_RD);
265 shutdown(1, SHUT_WR); 265 shutdown(1, SHUT_WR);
266 rea = 0; 266 rea = 0;