forked from lthn/blockchain
Merge branch 'develop' into release
This commit is contained in:
commit
963dab33b0
9 changed files with 40 additions and 27 deletions
|
|
@ -15,9 +15,19 @@ set(VERSION "1.0")
|
|||
|
||||
|
||||
set_property(GLOBAL PROPERTY USE_FOLDERS ON)
|
||||
set(CMAKE_CONFIGURATION_TYPES "Debug;Release")
|
||||
#set(CMAKE_BUILD_TYPE "Debug")
|
||||
|
||||
# build types
|
||||
if (UNIX AND NOT APPLE)
|
||||
# single configurations, defaults to Release
|
||||
if (NOT CMAKE_BUILD_TYPE)
|
||||
set(CMAKE_BUILD_TYPE "Release")
|
||||
endif()
|
||||
else()
|
||||
# multi configurations for MSVC and XCode
|
||||
set(CMAKE_CONFIGURATION_TYPES "Debug;Release")
|
||||
endif()
|
||||
message("Generated with config types: ${CMAKE_CONFIGURATION_TYPES}, and built type: ${CMAKE_BUILD_TYPE}")
|
||||
|
||||
enable_testing()
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -27,9 +27,11 @@
|
|||
namespace crypto {
|
||||
|
||||
DISABLE_GCC_AND_CLANG_WARNING(strict-aliasing)
|
||||
const unsigned char Z_[32] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 };
|
||||
const unsigned char I_[32] = { 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 };
|
||||
const unsigned char L_[32] = { 0xed, 0xd3, 0xf5, 0x5c, 0x1a, 0x63, 0x12, 0x58, 0xd6, 0x9c, 0xf7, 0xa2, 0xde, 0xf9, 0xde, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10 };
|
||||
|
||||
const key_image Z = *reinterpret_cast<const key_image*>(&Z_);
|
||||
const key_image I = *reinterpret_cast<const key_image*>(&I_);
|
||||
const key_image L = *reinterpret_cast<const key_image*>(&L_);
|
||||
|
||||
|
|
@ -148,10 +150,7 @@ namespace crypto {
|
|||
ge_p3 A = ge_p3();
|
||||
ge_p2 R = ge_p2();
|
||||
if (ge_frombytes_vartime(&A, reinterpret_cast<const unsigned char*>(&P)) != 0)
|
||||
{
|
||||
crypto_assert(false);
|
||||
throw std::runtime_error(__func__);
|
||||
}
|
||||
return Z;
|
||||
ge_scalarmult(&R, reinterpret_cast<const unsigned char*>(&a), &A);
|
||||
key_image a_p = key_image();
|
||||
ge_tobytes(reinterpret_cast<unsigned char*>(&a_p), &R);
|
||||
|
|
@ -161,9 +160,8 @@ namespace crypto {
|
|||
bool crypto_ops::validate_key_image(const key_image& ki)
|
||||
{
|
||||
if (!(scalarmult_key(ki, L) == I))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -47,8 +47,8 @@
|
|||
#define BASE_REWARD_DUST_THRESHOLD ((uint64_t)1000000) // pow(10, 6) - change this will cause hard-fork!
|
||||
#define DEFAULT_DUST_THRESHOLD ((uint64_t)0)//((uint64_t)100000) // pow(10, 5)
|
||||
|
||||
#define TX_DEFAULT_FEE ((uint64_t)10000000000) // pow(10, 5)
|
||||
#define TX_MINIMUM_FEE ((uint64_t)100000) // pow(10, 5)
|
||||
#define TX_DEFAULT_FEE ((uint64_t)10000000000) // .01
|
||||
#define TX_MINIMUM_FEE ((uint64_t)10000000000) // .01
|
||||
|
||||
// #define CURRENCY_FIXED_REWARD_ZONE_HEIGHT 300 // blocks will have fixed reward up to this height (including)
|
||||
// #define CURRENCY_FIXED_REWARD_ZONE_REWARD_AMOUNT ((uint64_t)100000000) // should be TX_MINIMUM_FEE * CURRENCY_FIXED_REWARD_ZONE_FEE_MULTIPLIER
|
||||
|
|
|
|||
|
|
@ -866,7 +866,8 @@ var Wallet = /** @class */ (function () {
|
|||
amount: null,
|
||||
comment: null,
|
||||
mixin: null,
|
||||
fee: null
|
||||
fee: null,
|
||||
hide: null
|
||||
};
|
||||
this.wallet_id = id;
|
||||
this.name = name;
|
||||
|
|
@ -6037,7 +6038,8 @@ var SendComponent = /** @class */ (function () {
|
|||
amount: _this.variablesService.currentWallet.send_data['amount'],
|
||||
comment: _this.variablesService.currentWallet.send_data['comment'],
|
||||
mixin: _this.variablesService.currentWallet.send_data['mixin'] || 0,
|
||||
fee: _this.variablesService.currentWallet.send_data['fee'] || _this.variablesService.default_fee
|
||||
fee: _this.variablesService.currentWallet.send_data['fee'] || _this.variablesService.default_fee,
|
||||
hide: _this.variablesService.currentWallet.send_data['hide'] || false
|
||||
});
|
||||
});
|
||||
};
|
||||
|
|
@ -6055,8 +6057,8 @@ var SendComponent = /** @class */ (function () {
|
|||
_this.backend.sendMoney(_this.currentWalletId, _this.sendForm.get('address').value, _this.sendForm.get('amount').value, _this.sendForm.get('fee').value, _this.sendForm.get('mixin').value, _this.sendForm.get('comment').value, _this.sendForm.get('hide').value, function (send_status) {
|
||||
if (send_status) {
|
||||
_this.modalService.prepareModal('success', 'SEND.SUCCESS_SENT');
|
||||
_this.variablesService.currentWallet.send_data = { address: null, amount: null, comment: null, mixin: null, fee: null };
|
||||
_this.sendForm.reset({ address: null, amount: null, comment: null, mixin: 0, fee: _this.variablesService.default_fee });
|
||||
_this.variablesService.currentWallet.send_data = { address: null, amount: null, comment: null, mixin: null, fee: null, hide: null };
|
||||
_this.sendForm.reset({ address: null, amount: null, comment: null, mixin: 0, fee: _this.variablesService.default_fee, hide: false });
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
@ -6075,8 +6077,8 @@ var SendComponent = /** @class */ (function () {
|
|||
_this.sendForm.get('amount').value, _this.sendForm.get('fee').value, _this.sendForm.get('mixin').value, _this.sendForm.get('comment').value, _this.sendForm.get('hide').value, function (send_status) {
|
||||
if (send_status) {
|
||||
_this.modalService.prepareModal('success', 'SEND.SUCCESS_SENT');
|
||||
_this.variablesService.currentWallet.send_data = { address: null, amount: null, comment: null, mixin: null, fee: null };
|
||||
_this.sendForm.reset({ address: null, amount: null, comment: null, mixin: 0, fee: _this.variablesService.default_fee });
|
||||
_this.variablesService.currentWallet.send_data = { address: null, amount: null, comment: null, mixin: null, fee: null, hide: null };
|
||||
_this.sendForm.reset({ address: null, amount: null, comment: null, mixin: 0, fee: _this.variablesService.default_fee, hide: false });
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
@ -6095,7 +6097,8 @@ var SendComponent = /** @class */ (function () {
|
|||
amount: this.sendForm.get('amount').value,
|
||||
comment: this.sendForm.get('comment').value,
|
||||
mixin: this.sendForm.get('mixin').value,
|
||||
fee: this.sendForm.get('fee').value
|
||||
fee: this.sendForm.get('fee').value,
|
||||
hide: this.sendForm.get('hide').value
|
||||
};
|
||||
};
|
||||
__decorate([
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
|
|
@ -33,7 +33,8 @@ export class Wallet {
|
|||
amount: null,
|
||||
comment: null,
|
||||
mixin: null,
|
||||
fee: null
|
||||
fee: null,
|
||||
hide: null
|
||||
};
|
||||
|
||||
constructor(id, name, pass, path, address, balance, unlocked_balance, mined = 0, tracking = '') {
|
||||
|
|
|
|||
|
|
@ -126,7 +126,8 @@ export class SendComponent implements OnInit, OnDestroy {
|
|||
amount: this.variablesService.currentWallet.send_data['amount'],
|
||||
comment: this.variablesService.currentWallet.send_data['comment'],
|
||||
mixin: this.variablesService.currentWallet.send_data['mixin'] || 0,
|
||||
fee: this.variablesService.currentWallet.send_data['fee'] || this.variablesService.default_fee
|
||||
fee: this.variablesService.currentWallet.send_data['fee'] || this.variablesService.default_fee,
|
||||
hide: this.variablesService.currentWallet.send_data['hide'] || false
|
||||
});
|
||||
});
|
||||
}
|
||||
|
|
@ -151,8 +152,8 @@ export class SendComponent implements OnInit, OnDestroy {
|
|||
(send_status) => {
|
||||
if (send_status) {
|
||||
this.modalService.prepareModal('success', 'SEND.SUCCESS_SENT');
|
||||
this.variablesService.currentWallet.send_data = {address: null, amount: null, comment: null, mixin: null, fee: null};
|
||||
this.sendForm.reset({address: null, amount: null, comment: null, mixin: 0, fee: this.variablesService.default_fee});
|
||||
this.variablesService.currentWallet.send_data = {address: null, amount: null, comment: null, mixin: null, fee: null, hide: null};
|
||||
this.sendForm.reset({address: null, amount: null, comment: null, mixin: 0, fee: this.variablesService.default_fee, hide: false});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
@ -176,8 +177,8 @@ export class SendComponent implements OnInit, OnDestroy {
|
|||
(send_status) => {
|
||||
if (send_status) {
|
||||
this.modalService.prepareModal('success', 'SEND.SUCCESS_SENT');
|
||||
this.variablesService.currentWallet.send_data = {address: null, amount: null, comment: null, mixin: null, fee: null};
|
||||
this.sendForm.reset({address: null, amount: null, comment: null, mixin: 0, fee: this.variablesService.default_fee});
|
||||
this.variablesService.currentWallet.send_data = {address: null, amount: null, comment: null, mixin: null, fee: null, hide: null};
|
||||
this.sendForm.reset({address: null, amount: null, comment: null, mixin: 0, fee: this.variablesService.default_fee, hide: false});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
@ -198,7 +199,8 @@ export class SendComponent implements OnInit, OnDestroy {
|
|||
amount: this.sendForm.get('amount').value,
|
||||
comment: this.sendForm.get('comment').value,
|
||||
mixin: this.sendForm.get('mixin').value,
|
||||
fee: this.sendForm.get('fee').value
|
||||
fee: this.sendForm.get('fee').value,
|
||||
hide: this.sendForm.get('hide').value
|
||||
};
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -2,6 +2,6 @@
|
|||
|
||||
#define BUILD_COMMIT_ID "@VERSION@"
|
||||
#define PROJECT_VERSION "1.0"
|
||||
#define PROJECT_VERSION_BUILD_NO 30
|
||||
#define PROJECT_VERSION_BUILD_NO 31
|
||||
#define PROJECT_VERSION_BUILD_NO_STR STRINGIFY_EXPAND(PROJECT_VERSION_BUILD_NO)
|
||||
#define PROJECT_VERSION_LONG PROJECT_VERSION "." PROJECT_VERSION_BUILD_NO_STR "[" BUILD_COMMIT_ID "]"
|
||||
|
|
|
|||
|
|
@ -117,7 +117,6 @@ bool wallet_rpc_integrated_address_transfer::c1(currency::core& c, size_t ev_ind
|
|||
tools::wallet_rpc::COMMAND_RPC_TRANSFER::request req = AUTO_VAL_INIT(req);
|
||||
req.fee = TESTS_DEFAULT_FEE;
|
||||
req.mixin = 0;
|
||||
req.unlock_time = 0;
|
||||
tools::wallet_rpc::trnsfer_destination tds = AUTO_VAL_INIT(tds);
|
||||
tds.address = alice_integrated_address;
|
||||
tds.amount = MK_TEST_COINS(3);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue