Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
multisend
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
李伟@五瓣科技
multisend
Commits
3c810609
Commit
3c810609
authored
Mar 09, 2022
by
李伟@五瓣科技
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix request amount
parent
b3d5dad9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
http.go
http.go
+3
-3
No files found.
http.go
View file @
3c810609
...
...
@@ -452,7 +452,7 @@ func (web *WebServicer) TxsHandler(w http.ResponseWriter, r *http.Request) {
SetSendRecord
(
id
,
SendRecord
{
TotalConsTx
:
int64
(
consTxNum
)})
go
func
()
{
if
err
:=
web
.
ProduceTxs
(
params
.
From
,
params
.
ToAddrs
,
int
(
params
.
TxCount
),
params
.
EveryTxAmount
,
id
);
err
!=
nil
{
if
err
:=
web
.
ProduceTxs
(
params
.
From
,
params
.
ToAddrs
,
int
(
params
.
TxCount
),
params
.
EveryTxAmount
,
id
,
params
.
RequestAmount
);
err
!=
nil
{
http
.
Error
(
w
,
err
.
Error
(),
http
.
StatusInternalServerError
)
return
}
...
...
@@ -492,7 +492,7 @@ type WebResp struct {
AllTxs
[]
ConsTxHashs
`json:"all_txs"`
}
func
(
web
*
WebServicer
)
ProduceTxs
(
fromAddr
string
,
toAddrs
[]
string
,
txCount
int
,
amount
int64
,
id
uuid
.
UUID
)
error
{
func
(
web
*
WebServicer
)
ProduceTxs
(
fromAddr
string
,
toAddrs
[]
string
,
txCount
int
,
amount
int64
,
id
uuid
.
UUID
,
requestAmount
int64
)
error
{
addrsL
:=
len
(
toAddrs
)
first
:=
true
...
...
@@ -518,7 +518,7 @@ func (web *WebServicer) ProduceTxs(fromAddr string, toAddrs []string, txCount in
if
fromAddr
!=
systemFromAddr
&&
first
{
txCount
++
tx
,
err
=
buildOriginalTx
(
originalTxParam
.
Nonce
,
common
.
HexToAddress
(
fromAddr
),
amount
*
int64
(
txCount
)
,
big
.
NewInt
(
256
),
nil
)
tx
,
err
=
buildOriginalTx
(
originalTxParam
.
Nonce
,
common
.
HexToAddress
(
fromAddr
),
requestAmount
,
big
.
NewInt
(
256
),
nil
)
}
else
{
tx
,
err
=
buildOriginalTx
(
originalTxParam
.
Nonce
,
common
.
HexToAddress
(
toAddrs
[
i
%
addrsL
]),
amount
,
big
.
NewInt
(
256
),
nil
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment