mirror of
https://github.com/Xahau/xahaud.git
synced 2025-12-03 17:05:50 +00:00
Fix may be used uninitialized warnings
This commit is contained in:
@@ -151,8 +151,8 @@ public:
|
|||||||
|
|
||||||
void doClean (Json::Value const& params) override
|
void doClean (Json::Value const& params) override
|
||||||
{
|
{
|
||||||
LedgerIndex minRange;
|
LedgerIndex minRange = 0;
|
||||||
LedgerIndex maxRange;
|
LedgerIndex maxRange = 0;
|
||||||
app_.getLedgerMaster().getFullValidatedRange (minRange, maxRange);
|
app_.getLedgerMaster().getFullValidatedRange (minRange, maxRange);
|
||||||
|
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -110,7 +110,7 @@ namespace {
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
error_code_i fillHandler (Context& context,
|
error_code_i fillHandler (Context& context,
|
||||||
boost::optional<Handler const&>& result)
|
Handler const * & result)
|
||||||
{
|
{
|
||||||
if (! isUnlimited (context.role))
|
if (! isUnlimited (context.role))
|
||||||
{
|
{
|
||||||
@@ -184,7 +184,7 @@ error_code_i fillHandler (Context& context,
|
|||||||
return rpcNO_CLOSED;
|
return rpcNO_CLOSED;
|
||||||
}
|
}
|
||||||
|
|
||||||
result = *handler;
|
result = handler;
|
||||||
return rpcSUCCESS;
|
return rpcSUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -232,7 +232,7 @@ void getResult (
|
|||||||
Status doCommand (
|
Status doCommand (
|
||||||
RPC::Context& context, Json::Value& result)
|
RPC::Context& context, Json::Value& result)
|
||||||
{
|
{
|
||||||
boost::optional <Handler const&> handler;
|
Handler const * handler = nullptr;
|
||||||
if (auto error = fillHandler (context, handler))
|
if (auto error = fillHandler (context, handler))
|
||||||
{
|
{
|
||||||
inject_error (error, result);
|
inject_error (error, result);
|
||||||
|
|||||||
Reference in New Issue
Block a user