Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
Nettle
nettle
Commits
73d3c6d5
Commit
73d3c6d5
authored
Jan 06, 2019
by
Niels Möller
1
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tests: Fix assert call with side effects.
parent
c8f4de1f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
1 deletion
+8
-1
ChangeLog
ChangeLog
+5
-0
testsuite/rsa-compute-root-test.c
testsuite/rsa-compute-root-test.c
+3
-1
No files found.
ChangeLog
View file @
73d3c6d5
2019-01-06 Niels Möller <nisse@lysator.liu.se>
* testsuite/rsa-compute-root-test.c (generate_keypair): Fix assert
call with side-effects.
2018-02-18 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
Backported from master branch.
...
...
testsuite/rsa-compute-root-test.c
View file @
73d3c6d5
...
...
@@ -86,6 +86,7 @@ generate_keypair (gmp_randstate_t rands,
mpz_t
q1
;
mpz_t
phi
;
mpz_t
tmp
;
int
res
;
mpz_init
(
p1
);
mpz_init
(
q1
);
...
...
@@ -124,7 +125,8 @@ generate_keypair (gmp_randstate_t rands,
}
mpz_mul
(
phi
,
p1
,
q1
);
assert
(
mpz_invert
(
key
->
d
,
pub
->
e
,
phi
));
res
=
mpz_invert
(
key
->
d
,
pub
->
e
,
phi
);
assert
(
res
);
mpz_fdiv_r
(
key
->
a
,
key
->
d
,
p1
);
mpz_fdiv_r
(
key
->
b
,
key
->
d
,
q1
);
...
...
Niels Möller
@nisse
mentioned in commit
1f5b9812
·
Jan 10, 2019
mentioned in commit
1f5b9812
mentioned in commit 1f5b9812dec00811344ab080444c0582f6405533
Toggle commit list
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