AMD64 Portability issues. Boost version issue.

This commit is contained in:
Robin Davies
2021-08-23 22:43:05 -04:00
parent 264a32d3b2
commit 8c239dc898
4 changed files with 37 additions and 16 deletions
+7
View File
@@ -170,5 +170,12 @@ react/node_modules/workbox-build/node_modules/source-map/:
copyright: 2009-2011, 2014, Mozilla Foundation and contributors copyright: 2009-2011, 2014, Mozilla Foundation and contributors
license: BSD-2-clause license: BSD-2-clause
react/node_modules/atob/:
copyright: 2012-2018, AJ ONeal
license: Apache-2.0 or Expat
+1 -1
View File
@@ -74,7 +74,7 @@ public:
}; };
class PedalBoardItem: public JsonWritable { class PedalBoardItem: public JsonWritable {
long instanceId_ = 0; int64_t instanceId_ = 0;
std::string uri_; std::string uri_;
std::string pluginName_; std::string pluginName_;
bool isEnabled_ = true; bool isEnabled_ = true;
+1 -1
View File
@@ -293,7 +293,7 @@ private:
void StartAccept() void StartAccept()
{ {
// socket // socket
std::shared_ptr<Reader> reader = Reader::Create(acceptor_.get_io_service()); std::shared_ptr<Reader> reader = Reader::Create(acceptor_.get_executor().context());
// asynchronous accept operation and wait for a new connection. // asynchronous accept operation and wait for a new connection.
acceptor_.async_accept(reader->Socket(), acceptor_.async_accept(reader->Socket(),
+28 -14
View File
@@ -283,23 +283,27 @@ public:
{ {
this->CRLF = compressed? "" : "\r\n"; this->CRLF = compressed? "" : "\r\n";
} }
void write(long long value)
{
os << value;
}
void write(unsigned long long value)
{
os << value;
}
void write(long value) void write(long value)
{ {
os << value; os << value;
} }
void write(int64_t value) void write(unsigned long value)
{ {
os << value; os << value;
} }
void write(uint64_t value) void write(int value)
{ {
os << value; os << value;
} }
void write(int32_t value) void write(unsigned int value)
{
os << value;
}
void write(uint32_t value)
{ {
os << value; os << value;
} }
@@ -356,7 +360,7 @@ public:
{ {
write(value[0]); write(value[0]);
} }
for (int i = 1; i < value.size(); ++i) for (size_t i = 1; i < value.size(); ++i)
{ {
os << ","; os << ",";
write(value[i]); write(value[i]);
@@ -367,7 +371,7 @@ public:
os << "[" << CRLF; os << "[" << CRLF;
indent_level += TAB_SIZE; indent_level += TAB_SIZE;
bool first = true; bool first = true;
for (int i = 0; i < value.size(); ++i) for (size_t i = 0; i < value.size(); ++i)
{ {
if (!first) if (!first)
{ {
@@ -682,27 +686,37 @@ public:
skip_whitespace(); skip_whitespace();
*value = read_boolean(); *value = read_boolean();
} }
void read(int *value) {
skip_whitespace();
is_ >> *value;
if (is_.fail()) throw PiPedalException("Invalid format.");
}
void read(long*value) void read(long*value)
{ {
is_ >> *value; is_ >> *value;
if (is_.fail()) throw PiPedalException("Invalid format."); if (is_.fail()) throw PiPedalException("Invalid format.");
} }
void read(int32_t *value) { void read(long long*value) {
skip_whitespace(); skip_whitespace();
is_ >> *value; is_ >> *value;
if (is_.fail()) throw PiPedalException("Invalid format."); if (is_.fail()) throw PiPedalException("Invalid format.");
} }
void read(int64_t*value) { void read(int *value) {
skip_whitespace(); skip_whitespace();
is_ >> *value; is_ >> *value;
if (is_.fail()) throw PiPedalException("Invalid format."); if (is_.fail()) throw PiPedalException("Invalid format.");
} }
void read(uint32_t *value) { void read(unsigned int*value)
skip_whitespace(); {
is_ >> *value; is_ >> *value;
if (is_.fail()) throw PiPedalException("Invalid format."); if (is_.fail()) throw PiPedalException("Invalid format.");
} }
void read(uint64_t*value) { void read(unsigned long*value)
{
is_ >> *value;
if (is_.fail()) throw PiPedalException("Invalid format.");
}
void read(unsigned long long*value) {
skip_whitespace(); skip_whitespace();
is_ >> *value; is_ >> *value;
if (is_.fail()) throw PiPedalException("Invalid format."); if (is_.fail()) throw PiPedalException("Invalid format.");