We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 42dc35d + d248417 commit 2301588Copy full SHA for 2301588
src/libwalletqt/UnsignedTransaction.cpp
@@ -19,7 +19,7 @@ QString UnsignedTransaction::errorString() const
19
quint64 UnsignedTransaction::amount(size_t index) const
20
{
21
std::vector<uint64_t> arr = m_pimpl->amount();
22
- if(index > arr.size() - 1)
+ if(arr.empty() || index >= arr.size())
23
return 0;
24
return arr[index];
25
}
0 commit comments