summaryrefslogtreecommitdiff
path: root/libio/tst-fopenloc.c
diff options
context:
space:
mode:
authorSamuel Thibault <samuel.thibault@ens-lyon.org>2018-12-27 15:41:39 +0000
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2018-12-27 15:41:39 +0000
commit16c9ca827cd735002dec5689f93f22fc358d6f56 (patch)
treefbfaa8e020a3a762a96c4f219d4150e369e00099 /libio/tst-fopenloc.c
parentdaa262720d3dc357a298b18a359551994082c9b3 (diff)
parent963c37d5c0eb62b38f8764b23931c0dcdd497a13 (diff)
Merge commit 'refs/top-bases/t/bits_atomic.h_multiple_threads' into t/bits_atomic.h_multiple_threadst/bits_atomic.h_multiple_threads
Diffstat (limited to 'libio/tst-fopenloc.c')
-rw-r--r--libio/tst-fopenloc.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/libio/tst-fopenloc.c b/libio/tst-fopenloc.c
index 0f7edb64e9..59f63d27fc 100644
--- a/libio/tst-fopenloc.c
+++ b/libio/tst-fopenloc.c
@@ -1,5 +1,5 @@
/* Test for ,ccs= handling in fopen.
- Copyright (C) 2001-2016 Free Software Foundation, Inc.
+ Copyright (C) 2001-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 2001.
@@ -26,9 +26,13 @@
#include <wchar.h>
#include <sys/resource.h>
-
static const char inputfile[] = "../iconvdata/testdata/ISO-8859-1";
+static int do_test(void);
+
+#define TEST_FUNCTION do_test ()
+#include "../test-skeleton.c"
+
static int
do_bz17916 (void)
{
@@ -39,7 +43,7 @@ do_bz17916 (void)
setrlimit (RLIMIT_STACK, &rl);
const size_t sz = 2 * 1024 * 1024;
- char *ccs = malloc (sz);
+ char *ccs = xmalloc (sz);
strcpy (ccs, "r,ccs=");
memset (ccs + 6, 'A', sz - 6 - 1);
ccs[sz - 1] = '\0';
@@ -85,6 +89,3 @@ do_test (void)
return do_bz17916 ();
}
-
-#define TEST_FUNCTION do_test ()
-#include "../test-skeleton.c"