summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorvlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4>2017-05-24 09:15:54 +0000
committervlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4>2017-05-24 09:15:54 +0000
commit354c5ef6c32fc6a0c24ff13f2aafffb52225a67f (patch)
treeb64ada5901fede96c8b2af719659049d16710b8b
parent84a39d87999da7a456e6d1f8e243ec07c97b4485 (diff)
downloadmpfr-354c5ef6c32fc6a0c24ff13f2aafffb52225a67f.tar.gz
[src] Moved "#include <errno.h>" from printf.c to vasprintf.c
(this should have been done in r5230, where EOVERFLOW was moved). This fixes the "Got r = -1, errno = 0" errors in tprintf with MPFR_CHECK_LARGEMEM=1. git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/trunk@11532 280ebfd0-de03-0410-8827-d642c229c3f4
-rw-r--r--src/printf.c1
-rw-r--r--src/vasprintf.c2
2 files changed, 2 insertions, 1 deletions
diff --git a/src/printf.c b/src/printf.c
index 4828b6365..65858d1a9 100644
--- a/src/printf.c
+++ b/src/printf.c
@@ -41,7 +41,6 @@ http://www.gnu.org/licenses/ or write to the Free Software Foundation, Inc.,
# endif /* HAVE___VA_COPY */
#endif /* HAVE_VA_COPY */
-#include <errno.h>
#include "mpfr-impl.h"
#ifdef _MPFR_H_HAVE_FILE
diff --git a/src/vasprintf.c b/src/vasprintf.c
index a5c0c3e49..0ad301c9d 100644
--- a/src/vasprintf.c
+++ b/src/vasprintf.c
@@ -71,6 +71,8 @@ http://www.gnu.org/licenses/ or write to the Free Software Foundation, Inc.,
#include <stddef.h> /* for ptrdiff_t */
#endif
+#include <errno.h>
+
#define MPFR_NEED_LONGLONG_H
#include "mpfr-intmax.h"
#include "mpfr-impl.h"