Skip to content

Commit

Permalink
Fix code ambiguity
Browse files Browse the repository at this point in the history
  • Loading branch information
JamesSmartCell committed Jun 26, 2023
1 parent cd4d341 commit d7fcc61
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 2 deletions.
1 change: 0 additions & 1 deletion src/Contract.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -329,7 +329,6 @@ vector<uint8_t> Contract::RlpEncode(

auto *zeroStr = new string("0");
vector<uint8_t> zero = Util::ConvertHexToVector(zeroStr);

vector<uint8_t> outputNonce = Util::RlpEncodeItemWithVector(nonce);
vector<uint8_t> outputGasPrice = Util::RlpEncodeItemWithVector(gasPrice);
vector<uint8_t> outputGasLimit = Util::RlpEncodeItemWithVector(gasLimit);
Expand Down
6 changes: 6 additions & 0 deletions src/TcpBridge.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,12 @@ void TcpBridge::checkClientAPI(TcpBridgeCallback callback)
}
}

// Get Diff from last time we had server comms
long TcpBridge::getLastCommsTime()
{
return lastComms;
}

void TcpBridge::sendResponse(std::string resp)
{
packetBuffer[0] = 0x08;
Expand Down
2 changes: 2 additions & 0 deletions src/TcpBridge.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ class TcpBridge : public WiFiClient
int getConnectionStatus() { return connectionValidCountdown; }
int getPort() { return port; }

long getLastCommsTime();

private:
void scanAPI(APIReturn *apiReturn, int available);
std::string getArg(int &index);
Expand Down
2 changes: 1 addition & 1 deletion src/Web3.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ string Web3::getString(const string *json)
vector<string> *v = Util::ConvertStringHexToABIArray(&parseVal);

uint256_t length = uint256_t(v->at(1));
int lengthIndex = (size_t)length;
uint32_t lengthIndex = length;

string asciiHex;
int index = 2;
Expand Down

0 comments on commit d7fcc61

Please sign in to comment.