summaryrefslogtreecommitdiff
blob: 283ef2d7da90af6bceec1a74865391866612c9c9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
From 5669e7ea665323ee774eda9c77206102fa499453 Mon Sep 17 00:00:00 2001
From: Hideyuki Tanaka <tanaka.hideyuki@gmail.com>
Date: Mon, 21 May 2012 17:21:34 +0900
Subject: [PATCH] add include <unistd.h> (for gcc-4.7.0)

---
 src/network/socket.cpp |    1 +
 src/system/mmapper.cpp |    1 +
 tools/genrpc/main.cpp  |    1 +
 3 files changed, 3 insertions(+)

diff --git a/src/network/socket.cpp b/src/network/socket.cpp
index b5c50e4..1fba6e6 100644
--- a/src/network/socket.cpp
+++ b/src/network/socket.cpp
@@ -40,6 +40,7 @@
 #include <netinet/in.h>
 #include <netinet/tcp.h>
 #include <arpa/inet.h>
+#include <unistd.h>
 
 #include "dns.h"
 #include "../system/syscall.h"
diff --git a/src/system/mmapper.cpp b/src/system/mmapper.cpp
index 90eb7b8..e963fd8 100644
--- a/src/system/mmapper.cpp
+++ b/src/system/mmapper.cpp
@@ -35,6 +35,7 @@
 #include <sys/stat.h>
 #include <fcntl.h>
 #include <sys/mman.h>
+#include <unistd.h>
 
 #include "syscall.h"
 
diff --git a/tools/genrpc/main.cpp b/tools/genrpc/main.cpp
index 100ea4e..3e5ef16 100644
--- a/tools/genrpc/main.cpp
+++ b/tools/genrpc/main.cpp
@@ -4,6 +4,7 @@
 #include <cctype>
 #include <cstring>
 #include <cstdio>
+#include <unistd.h>
 using namespace std;
 
 #include "../../src/lang/shared_ptr.h"
-- 
1.7.10