diff options
author | David S. Miller <davem@davemloft.net> | 2016-11-26 23:42:21 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-11-26 23:42:21 -0500 |
commit | 0b42f25d2f123bb7fbd3565d003a8ea9e1e810fe (patch) | |
tree | 77856ad061e97e86027df1fa6efdf20a9fe309b5 /lib | |
parent | e5f12b3f5ebb8a6ffd3864a04f687ea0ef78a48a (diff) | |
parent | d8e435f3ab6fea2ea324dce72b51dd7761747523 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
udplite conflict is resolved by taking what 'net-next' did
which removed the backlog receive method assignment, since
it is no longer necessary.
Two entries were added to the non-priv ethtool operations
switch statement, one in 'net' and one in 'net-next, so
simple overlapping changes.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/mpi/mpi-pow.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/mpi/mpi-pow.c b/lib/mpi/mpi-pow.c index 5464c8744ea9..e24388a863a7 100644 --- a/lib/mpi/mpi-pow.c +++ b/lib/mpi/mpi-pow.c @@ -64,8 +64,13 @@ int mpi_powm(MPI res, MPI base, MPI exp, MPI mod) if (!esize) { /* Exponent is zero, result is 1 mod MOD, i.e., 1 or 0 * depending on if MOD equals 1. */ - rp[0] = 1; res->nlimbs = (msize == 1 && mod->d[0] == 1) ? 0 : 1; + if (res->nlimbs) { + if (mpi_resize(res, 1) < 0) + goto enomem; + rp = res->d; + rp[0] = 1; + } res->sign = 0; goto leave; } |