summaryrefslogtreecommitdiff
path: root/mpz/import.c
diff options
context:
space:
mode:
authorTorbjorn Granlund <tege@gmplib.org>2012-05-26 15:57:43 +0200
committerTorbjorn Granlund <tege@gmplib.org>2012-05-26 15:57:43 +0200
commiteb3632bb2177f6ea7d2f41c9722458c10159c013 (patch)
tree624a47bf95ce22460938a693f797937f5d6003cb /mpz/import.c
parent27ac5bf5c349d49c7103674b4a366afb6ad51cca (diff)
downloadgmp-eb3632bb2177f6ea7d2f41c9722458c10159c013.tar.gz
Use MPZ_REALLOC return value when possible.
Diffstat (limited to 'mpz/import.c')
-rw-r--r--mpz/import.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/mpz/import.c b/mpz/import.c
index d15568ce9..1585d67e1 100644
--- a/mpz/import.c
+++ b/mpz/import.c
@@ -1,6 +1,6 @@
/* mpz_import -- set mpz from word data.
-Copyright 2002 Free Software Foundation, Inc.
+Copyright 2002, 2012 Free Software Foundation, Inc.
This file is part of the GNU MP Library.
@@ -47,8 +47,7 @@ mpz_import (mpz_ptr z, size_t count, int order,
ASSERT (nail <= 8*size);
zsize = (count * (8*size - nail) + GMP_NUMB_BITS-1) / GMP_NUMB_BITS;
- MPZ_REALLOC (z, zsize);
- zp = PTR(z);
+ zp = MPZ_REALLOC (z, zsize);
if (endian == 0)
endian = HOST_ENDIAN;