Jeffrey Altman
31d5c38976
lib/hcrypto: mpz2BN return NULL if mp_ubin_size(s) returns zero
...
If mp_ubin_size(s) returns zero then mp_to_ubin() will fail and
not return MP_OKAY. If MP_OKAY is not returned, NULL is returned
to the caller of mpz2BN().
This change avoids the unnecessary memory allocation and function
calls. It also removes a dereference after null warning from
coverity.
Change-Id: I52ff2c166964e41cb4eef1dac637904bf2bf13bf
2022-01-24 10:14:17 -05:00
..
2022-01-21 10:39:47 -05:00
2020-04-25 23:19:30 -05:00
2016-04-10 17:05:07 -05:00
2010-08-15 15:06:58 -07:00
2022-01-15 23:17:26 -05:00
2016-04-15 00:16:17 -05:00
2016-04-10 17:05:07 -05:00
2018-04-09 14:50:17 -04:00
2016-04-10 17:05:07 -05:00
2010-08-20 13:03:34 -04:00
2008-09-13 08:53:55 +00:00
2016-04-10 17:05:07 -05:00
2010-08-15 15:06:58 -07:00
2008-09-13 09:21:03 +00:00
2022-01-20 21:29:11 -05:00
2011-05-21 11:57:31 -07:00
2007-11-14 20:04:50 +00:00
2016-04-10 17:05:07 -05:00
2022-01-17 21:41:21 -05:00
2016-04-10 17:05:07 -05:00
2022-01-17 21:27:00 -05:00
2016-04-15 00:16:17 -05:00
2008-09-13 09:21:03 +00:00
2016-04-10 17:05:07 -05:00
2016-04-15 00:16:17 -05:00
2021-11-29 12:50:26 +11:00
2021-11-29 12:50:26 +11:00
2021-11-29 12:50:26 +11:00
2021-11-29 12:50:26 +11:00
2022-01-16 14:08:22 -06:00
2016-04-15 00:16:17 -05:00
2016-06-09 01:13:14 -04:00
2015-12-04 23:56:12 +11:00
2016-04-10 17:05:07 -05:00
2016-04-10 17:05:07 -05:00
2010-09-30 18:22:00 -07:00
2016-12-17 23:04:41 -05:00
2016-04-15 00:16:17 -05:00
2019-05-18 17:15:26 -04:00
2015-12-09 11:08:35 +11:00
2016-04-19 13:40:47 -05:00
2015-02-11 16:00:32 +11:00
2019-12-05 20:20:28 -05:00
2015-02-11 16:00:32 +11:00
2022-01-13 16:00:50 -05:00
2018-05-11 13:11:31 +10:00
2016-11-11 14:30:13 -06:00
2007-04-20 08:29:05 +00:00
2016-11-09 14:22:38 +00:00
2022-01-14 12:48:32 -06:00
2022-01-14 12:48:32 -06:00
2020-04-25 23:19:30 -05:00
2022-01-14 20:10:19 -06:00
2017-04-29 01:05:59 -04:00
2015-02-11 16:00:32 +11:00
2016-04-10 17:05:07 -05:00
2015-02-11 16:00:32 +11:00
2016-04-10 17:05:07 -05:00
2015-02-11 16:00:32 +11:00
2016-04-10 17:05:07 -05:00
2016-04-15 00:16:17 -05:00
2020-04-25 23:19:30 -05:00
2007-04-20 08:29:05 +00:00
2007-04-20 08:29:05 +00:00
2007-04-20 08:29:05 +00:00
2007-04-20 08:29:05 +00:00
2016-04-10 17:05:07 -05:00
2008-09-13 09:21:03 +00:00
2016-10-08 08:17:11 +02:00
2016-04-10 17:05:07 -05:00
2008-09-13 09:21:03 +00:00
2018-12-14 17:30:14 -05:00
2016-11-10 22:29:49 -05:00
2016-04-15 00:16:18 -05:00
2020-02-01 12:32:09 +11:00
2017-04-17 18:02:30 -04:00
2018-04-09 14:50:17 -04:00
2015-10-06 15:44:47 +02:00
2016-04-10 17:05:07 -05:00
2008-09-13 09:21:03 +00:00
2016-04-10 17:05:07 -05:00
2016-04-10 17:05:07 -05:00
2009-08-14 20:06:39 +02:00
2016-04-10 17:05:07 -05:00
2008-09-13 09:21:03 +00:00
2016-04-10 17:05:07 -05:00
2007-04-20 08:29:05 +00:00
2016-04-10 17:05:07 -05:00
2016-04-10 17:05:07 -05:00
2022-01-24 10:14:17 -05:00
2016-04-10 17:05:07 -05:00
2022-01-17 21:36:49 -05:00
2016-04-15 00:16:17 -05:00
2010-10-03 17:04:48 -07:00
2010-10-03 18:13:58 -07:00
2007-04-20 08:29:05 +00:00
2016-04-10 17:05:07 -05:00
2016-04-10 17:05:07 -05:00
2016-04-10 17:05:07 -05:00
2015-02-11 16:00:32 +11:00
2016-04-10 17:05:07 -05:00
2016-11-09 15:36:04 +00:00
2020-05-28 11:10:57 -04:00
2014-04-25 02:42:17 +02:00
2019-01-02 13:56:04 -05:00
2016-04-10 17:05:07 -05:00
2022-01-14 12:48:32 -06:00
2016-10-08 08:17:11 +02:00
2016-04-10 17:05:07 -05:00
2016-11-16 17:03:14 -06:00
2020-04-27 13:14:21 -05:00
2018-12-30 15:39:49 -06:00
2018-12-30 15:39:49 -06:00
2016-10-08 08:17:11 +02:00
2022-01-14 12:48:32 -06:00
2020-04-25 23:19:30 -05:00
2020-04-25 23:19:30 -05:00