diff --git a/Builds/VisualStudio2012/RippleD.vcxproj b/Builds/VisualStudio2012/RippleD.vcxproj
index dc35d9760..e646e1b68 100644
--- a/Builds/VisualStudio2012/RippleD.vcxproj
+++ b/Builds/VisualStudio2012/RippleD.vcxproj
@@ -998,6 +998,12 @@
true
true
+
+ true
+ true
+ true
+ true
+
true
@@ -1557,6 +1563,7 @@
+
diff --git a/Builds/VisualStudio2012/RippleD.vcxproj.filters b/Builds/VisualStudio2012/RippleD.vcxproj.filters
index 1226f51fe..71ad15054 100644
--- a/Builds/VisualStudio2012/RippleD.vcxproj.filters
+++ b/Builds/VisualStudio2012/RippleD.vcxproj.filters
@@ -160,6 +160,9 @@
{c69b07a2-44e5-4b06-99a9-81f5d137ea15}
+
+ {f0308442-e7af-44d4-a76a-c91fbf685e10}
+
@@ -882,6 +885,9 @@
[1] Ripple\ripple_app\main
+
+ [1] Ripple\ripple_net\protocol
+
@@ -1670,6 +1676,9 @@
[2] Build
+
+ [1] Ripple\ripple_net\protocol
+
diff --git a/Subtrees/beast/modules/beast_core/streams/beast_InputStream.h b/Subtrees/beast/modules/beast_core/streams/beast_InputStream.h
index 081a7b037..2b911bf18 100644
--- a/Subtrees/beast/modules/beast_core/streams/beast_InputStream.h
+++ b/Subtrees/beast/modules/beast_core/streams/beast_InputStream.h
@@ -239,14 +239,19 @@ public:
/** Reads a type using a template specialization.
The variable is passed as a parameter so that the template type
- can be deduced.
+ can be deduced. The return value indicates whether or not there
+ was sufficient data in the stream to read the value.
- This is useful when doing template meta-programming.
*/
template
- void readTypeInto (T* p)
+ bool readTypeInto (T* p)
{
- *p = readType ();
+ if (getNumBytesRemaining () >= sizeof (T))
+ {
+ *p = readType ();
+ return true;
+ }
+ return false;
}
/** Reads a type from a big endian stream using a template specialization.
@@ -262,14 +267,18 @@ public:
/** Reads a type using a template specialization.
The variable is passed as a parameter so that the template type
- can be deduced.
-
- This is useful when doing template meta-programming.
+ can be deduced. The return value indicates whether or not there
+ was sufficient data in the stream to read the value.
*/
template
- void readTypeBigEndianInto (T* p)
+ bool readTypeBigEndianInto (T* p)
{
- *p = readTypeBigEndian ();
+ if (getNumBytesRemaining () >= sizeof (T))
+ {
+ *p = readTypeBigEndian ();
+ return true;
+ }
+ return false;
}
//==============================================================================
diff --git a/modules/ripple_net/ripple_net.cpp b/modules/ripple_net/ripple_net.cpp
index a2ed5d803..f8694664b 100644
--- a/modules/ripple_net/ripple_net.cpp
+++ b/modules/ripple_net/ripple_net.cpp
@@ -25,4 +25,6 @@ namespace ripple
#include "basics/ripple_RPCServer.cpp"
#include "basics/ripple_SNTPClient.cpp"
+#include "protocol/ripple_ProxyProtocol.cpp"
+
}
diff --git a/modules/ripple_net/ripple_net.h b/modules/ripple_net/ripple_net.h
index 2452be7f9..d5bfdb672 100644
--- a/modules/ripple_net/ripple_net.h
+++ b/modules/ripple_net/ripple_net.h
@@ -32,6 +32,8 @@ namespace ripple
#include "basics/ripple_RPCServer.h"
#include "basics/ripple_SNTPClient.h"
+#include "protocol/ripple_ProxyProtocol.h"
+
}
#endif