#!/bin/bash
# Create a patch which backports the support/ subdirectory.
-# Copyright (C) 2017 Free Software Foundation, Inc.
+# Copyright (C) 2017-2018 Free Software Foundation, Inc.
# This file is part of the GNU C Library.
# The GNU C Library is free software; you can redistribute it and/or
# Makefile for support library, used only at build and test time
-# Copyright (C) 2016-2017 Free Software Foundation, Inc.
+# Copyright (C) 2016-2018 Free Software Foundation, Inc.
# This file is part of the GNU C Library.
# The GNU C Library is free software; you can redistribute it and/or
/* Capture output from a subprocess.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Support code for reporting test results.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
#include <support/check.h>
+#include <errno.h>
#include <stdarg.h>
#include <stdio.h>
#include <stdlib.h>
static void
print_failure (const char *file, int line, const char *format, va_list ap)
{
+ int saved_errno = errno;
printf ("error: %s:%d: ", file, line);
vprintf (format, ap);
puts ("");
+ errno = saved_errno;
}
int
/* Functionality for reporting test results.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
does not support reporting failures from a DSO. */
void support_record_failure (void);
+/* Static assertion, under a common name for both C++ and C11. */
+#ifdef __cplusplus
+# define support_static_assert static_assert
+#else
+# define support_static_assert _Static_assert
+#endif
+
/* Compare the two integers LEFT and RIGHT and report failure if they
are different. */
#define TEST_COMPARE(left, right) \
typedef __typeof__ (+ (right)) __right_type; \
__left_type __left_value = (left); \
__right_type __right_value = (right); \
- /* Prevent use with floating-point and boolean types. */ \
- _Static_assert ((__left_type) 1.0 == (__left_type) 1.5, \
- "left value has floating-point type"); \
- _Static_assert ((__right_type) 1.0 == (__right_type) 1.5, \
- "right value has floating-point type"); \
+ int __left_is_positive = __left_value > 0; \
+ int __right_is_positive = __right_value > 0; \
+ /* Prevent use with floating-point types. */ \
+ support_static_assert ((__left_type) 1.0 == (__left_type) 1.5, \
+ "left value has floating-point type"); \
+ support_static_assert ((__right_type) 1.0 == (__right_type) 1.5, \
+ "right value has floating-point type"); \
/* Prevent accidental use with larger-than-long long types. */ \
- _Static_assert (sizeof (__left_value) <= sizeof (long long), \
- "left value fits into long long"); \
- _Static_assert (sizeof (__right_value) <= sizeof (long long), \
+ support_static_assert (sizeof (__left_value) <= sizeof (long long), \
+ "left value fits into long long"); \
+ support_static_assert (sizeof (__right_value) <= sizeof (long long), \
"right value fits into long long"); \
- /* Make sure that integer conversions does not alter the sign. */ \
- enum \
- { \
- __left_is_unsigned = (__left_type) -1 > 0, \
- __right_is_unsigned = (__right_type) -1 > 0, \
- __unsigned_left_converts_to_wider = (__left_is_unsigned \
- && (sizeof (__left_value) \
- < sizeof (__right_value))), \
- __unsigned_right_converts_to_wider = (__right_is_unsigned \
- && (sizeof (__right_value) \
- < sizeof (__left_value))) \
- }; \
- _Static_assert (__left_is_unsigned == __right_is_unsigned \
- || __unsigned_left_converts_to_wider \
- || __unsigned_right_converts_to_wider, \
- "integer conversions may alter sign of operands"); \
/* Compare the value. */ \
- if (__left_value != __right_value) \
+ if (__left_value != __right_value \
+ || __left_is_positive != __right_is_positive) \
/* Pass the sign for printing the correct value. */ \
support_test_compare_failure \
(__FILE__, __LINE__, \
- #left, __left_value, __left_value < 0, sizeof (__left_type), \
- #right, __right_value, __right_value < 0, sizeof (__right_type)); \
+ #left, __left_value, __left_is_positive, sizeof (__left_type), \
+ #right, __right_value, __right_is_positive, sizeof (__right_type)); \
})
-/* Internal implementation of TEST_COMPARE. LEFT_NEGATIVE and
- RIGHT_NEGATIVE are used to store the sign separately, so that both
+/* Internal implementation of TEST_COMPARE. LEFT_POSITIVE and
+ RIGHT_POSITIVE are used to store the sign separately, so that both
unsigned long long and long long arguments fit into LEFT_VALUE and
RIGHT_VALUE, and the function can still print the original value.
LEFT_SIZE and RIGHT_SIZE specify the size of the argument in bytes,
void support_test_compare_failure (const char *file, int line,
const char *left_expr,
long long left_value,
- int left_negative,
+ int left_positive,
int left_size,
const char *right_expr,
long long right_value,
- int right_negative,
+ int right_positive,
int right_size);
/* Compare struct addrinfo values against a formatted string.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Check that a DNS packet buffer has the expected contents.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Compare struct hostent values against a formatted string.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Compare struct netent values against a formatted string.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Test verification functions for NSS- and DNS-related data.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Time-triggered process termination.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* String formatting functions for NSS- and DNS-related data.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Avoid all the buffer overflow messages on stderr.
- Copyright (C) 2015-2017 Free Software Foundation, Inc.
+ Copyright (C) 2015-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Entering namespaces for test case isolation.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Memory allocation next to an unmapped page.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Memory allocation next to an unmapped page.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Reporting out-of-memory errors.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* DNS test framework and libresolv redirection.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
max_response_length = 65536
};
-/* List of pointers to be freed. The hash table implementation
- (struct hsearch_data) does not provide a way to deallocate all
- objects, so this approach is used to avoid memory leaks. */
-struct to_be_freed
+/* Used for locating domain names containing for the purpose of
+ forming compression references. */
+struct compressed_name
{
- struct to_be_freed *next;
- void *ptr;
+ uint16_t offset;
+ unsigned char length;
+ unsigned char name[]; /* Without terminating NUL. */
};
+static struct compressed_name *
+allocate_compressed_name (const unsigned char *encoded, unsigned int offset)
+{
+ /* Compute the length of the domain name. */
+ size_t length;
+ {
+ const unsigned char *p;
+ for (p = encoded; *p != '\0';)
+ {
+ /* No compression references are allowed. */
+ TEST_VERIFY (*p <= 63);
+ /* Skip over the label. */
+ p += 1 + *p;
+ }
+ length = p - encoded;
+ ++length; /* For the terminating NUL byte. */
+ }
+ TEST_VERIFY_EXIT (length <= 255);
+
+ struct compressed_name *result
+ = xmalloc (offsetof (struct compressed_name, name) + length);
+ result->offset = offset;
+ result->length = length;
+ memcpy (result->name, encoded, length);
+ return result;
+}
+
+/* Convert CH to lower case. Only change letters in the ASCII
+ range. */
+static inline unsigned char
+ascii_tolower (unsigned char ch)
+{
+ if ('A' <= ch && ch <= 'Z')
+ return ch - 'A' + 'a';
+ else
+ return ch;
+}
+
+/* Compare both names, for use with tsearch. The order is arbitrary,
+ but the comparison is case-insenstive. */
+static int
+compare_compressed_name (const void *left, const void *right)
+{
+ const struct compressed_name *crleft = left;
+ const struct compressed_name *crright = right;
+
+ if (crleft->length != crright->length)
+ /* The operands are converted to int before the subtraction. */
+ return crleft->length - crright->length;
+
+ const unsigned char *nameleft = crleft->name;
+ const unsigned char *nameright = crright->name;
+
+ while (true)
+ {
+ int lenleft = *nameleft++;
+ int lenright = *nameright++;
+
+ /* Labels must not e compression references. */
+ TEST_VERIFY (lenleft <= 63);
+ TEST_VERIFY (lenright <= 63);
+
+ if (lenleft != lenright)
+ return left - right;
+ if (lenleft == 0)
+ /* End of name reached without spotting a difference. */
+ return 0;
+ /* Compare the label in a case-insenstive manner. */
+ const unsigned char *endnameleft = nameleft + lenleft;
+ while (nameleft < endnameleft)
+ {
+ int l = *nameleft++;
+ int r = *nameright++;
+ if (l != r)
+ {
+ l = ascii_tolower (l);
+ r = ascii_tolower (r);
+ if (l != r)
+ return l - r;
+ }
+ }
+ }
+}
+
struct resolv_response_builder
{
const unsigned char *query_buffer;
written RDATA sub-structure. 0 if no RDATA is being written. */
size_t current_rdata_offset;
- /* Hash table for locating targets for label compression. */
- struct hsearch_data compression_offsets;
- /* List of pointers which need to be freed. Used for domain names
- involved in label compression. */
- struct to_be_freed *to_be_freed;
+ /* tsearch tree for locating targets for label compression. */
+ void *compression_offsets;
/* Must be last. Not zeroed for performance reasons. */
unsigned char buffer[max_response_length];
/* Response builder. */
-/* Add a pointer to the list of pointers to be freed when B is
- deallocated. */
-static void
-response_push_pointer_to_free (struct resolv_response_builder *b, void *ptr)
-{
- if (ptr == NULL)
- return;
- struct to_be_freed *e = xmalloc (sizeof (*e));
- *e = (struct to_be_freed) {b->to_be_freed, ptr};
- b->to_be_freed = e;
-}
-
void
resolv_response_init (struct resolv_response_builder *b,
struct resolv_response_flags flags)
resolv_response_add_name (struct resolv_response_builder *b,
const char *const origname)
{
- /* Normalized name. */
- char *name;
- /* Normalized name with case preserved. */
- char *name_case;
- {
- size_t namelen = strlen (origname);
- /* Remove trailing dots. FIXME: Handle trailing quoted dots. */
- while (namelen > 0 && origname[namelen - 1] == '.')
- --namelen;
- name = xmalloc (namelen + 1);
- name_case = xmalloc (namelen + 1);
- /* Copy and convert to lowercase. FIXME: This needs to normalize
- escaping as well. */
- for (size_t i = 0; i < namelen; ++i)
- {
- char ch = origname[i];
- name_case[i] = ch;
- if ('A' <= ch && ch <= 'Z')
- ch = ch - 'A' + 'a';
- name[i] = ch;
- }
- name[namelen] = 0;
- name_case[namelen] = 0;
- }
- char *name_start = name;
- char *name_case_start = name_case;
+ unsigned char encoded_name[NS_MAXDNAME];
+ if (ns_name_pton (origname, encoded_name, sizeof (encoded_name)) < 0)
+ FAIL_EXIT1 ("ns_name_pton (\"%s\"): %m", origname);
- bool compression = false;
- while (*name)
+ /* Copy the encoded name into the output buffer, apply compression
+ where possible. */
+ for (const unsigned char *name = encoded_name; ;)
{
- /* Search for a previous name we can reference. */
- ENTRY new_entry =
+ if (*name == '\0')
{
- .key = name,
- .data = (void *) (uintptr_t) b->offset,
- };
+ /* We have reached the end of the name. Add the terminating
+ NUL byte. */
+ response_add_byte (b, '\0');
+ break;
+ }
- /* If the label can be a compression target because it is at a
- reachable offset, add it to the hash table. */
- ACTION action;
- if (b->offset < (1 << 12))
- action = ENTER;
- else
- action = FIND;
+ /* Set to the compression target if compression is possible. */
+ struct compressed_name *crname_target;
- /* Search for known compression offsets in the hash table. */
- ENTRY *e;
- if (hsearch_r (new_entry, action, &e, &b->compression_offsets) == 0)
- {
- if (action == FIND && errno == ESRCH)
- /* Fall through. */
- e = NULL;
- else
- FAIL_EXIT1 ("hsearch_r failure in name compression: %m");
- }
+ /* Compression references can only reach the beginning of the
+ packet. */
+ enum { compression_limit = 1 << 12 };
+
+ {
+ /* The trailing part of the name to be looked up in the tree
+ with the compression targets. */
+ struct compressed_name *crname
+ = allocate_compressed_name (name, b->offset);
+
+ if (b->offset < compression_limit)
+ {
+ /* Add the name to the tree, for future compression
+ references. */
+ void **ptr = tsearch (crname, &b->compression_offsets,
+ compare_compressed_name);
+ if (ptr == NULL)
+ FAIL_EXIT1 ("tsearch out of memory");
+ crname_target = *ptr;
+
+ if (crname_target != crname)
+ /* The new name was not actually added to the tree.
+ Deallocate it. */
+ free (crname);
+ else
+ /* Signal that the tree did not yet contain the name,
+ but keep the allocation because it is now part of the
+ tree. */
+ crname_target = NULL;
+ }
+ else
+ {
+ /* This name cannot be reached by a compression reference.
+ No need to add it to the tree for future reference. */
+ void **ptr = tfind (crname, &b->compression_offsets,
+ compare_compressed_name);
+ if (ptr != NULL)
+ crname_target = *ptr;
+ else
+ crname_target = NULL;
+ TEST_VERIFY (crname_target != crname);
+ /* Not added to the tree. */
+ free (crname);
+ }
+ }
- /* The name is known. Reference the previous location. */
- if (e != NULL && e->data != new_entry.data)
+ if (crname_target != NULL)
{
- size_t old_offset = (uintptr_t) e->data;
+ /* The name is known. Reference the previous location. */
+ unsigned int old_offset = crname_target->offset;
+ TEST_VERIFY_EXIT (old_offset < compression_limit);
response_add_byte (b, 0xC0 | (old_offset >> 8));
response_add_byte (b, old_offset);
- compression = true;
break;
}
-
- /* The name does not exist yet. Write one label. First, add
- room for the label length. */
- size_t buffer_label_offset = b->offset;
- response_add_byte (b, 0);
-
- /* Copy the label. */
- while (true)
+ else
{
- char ch = *name_case;
- if (ch == '\0')
- break;
- ++name;
- ++name_case;
- if (ch == '.')
- break;
- /* FIXME: Handle escaping. */
- response_add_byte (b, ch);
+ /* The name is new. Add this label. */
+ unsigned int len = 1 + *name;
+ resolv_response_add_data (b, name, len);
+ name += len;
}
-
- /* Patch in the label length. */
- size_t label_length = b->offset - buffer_label_offset - 1;
- if (label_length == 0)
- FAIL_EXIT1 ("empty label in name compression: %s", origname);
- if (label_length > 63)
- FAIL_EXIT1 ("label too long in name compression: %s", origname);
- b->buffer[buffer_label_offset] = label_length;
-
- /* Continue with the tail of the name and the next label. */
- }
-
- if (compression)
- {
- /* If we found an immediate match for the name, we have not put
- it into the hash table, and can free it immediately. */
- if (name == name_start)
- free (name_start);
- else
- response_push_pointer_to_free (b, name_start);
- }
- else
- {
- /* Terminate the sequence of labels. With compression, this is
- implicit in the compression reference. */
- response_add_byte (b, 0);
- response_push_pointer_to_free (b, name_start);
}
-
- free (name_case_start);
}
void
memset (b, 0, offsetof (struct resolv_response_builder, buffer));
b->query_buffer = query_buffer;
b->query_length = query_length;
- TEST_VERIFY_EXIT (hcreate_r (10000, &b->compression_offsets) != 0);
return b;
}
static void
response_builder_free (struct resolv_response_builder *b)
{
- struct to_be_freed *current = b->to_be_freed;
- while (current != NULL)
- {
- struct to_be_freed *next = current->next;
- free (current->ptr);
- free (current);
- current = next;
- }
- hdestroy_r (&b->compression_offsets);
+ tdestroy (b->compression_offsets, free);
free (b);
}
/* DNS test framework and libresolv redirection.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Invoke the system diff tool to compare two strings.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Set signal handler for use in fortify tests.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* fstat64 with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* stat64 with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Common extra functions.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Acquire root privileges.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Return true if the process can perform a chroot operation.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Capture output from a subprocess.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Verify capture output from a subprocess.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Setup a chroot environment for use within tests.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Enter a mount namespace.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
#include <sched.h>
#include <stdio.h>
-#include <sys/mount.h>
+#ifdef CLONE_NEWNS
+# include <sys/mount.h>
+#endif /* CLONE_NEWNS */
bool
support_enter_mount_namespace (void)
/* Enter a network namespace.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Convert an address family to a string.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Convert struct addrinfo values to a string.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Convert a DNS packet to a human-readable representation.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Convert a h_errno error code to a string.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Convert a struct hostent object to a string.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Convert a struct netent object to a string.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Run a function in a subprocess.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Global test failure counter.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Invoke the system diff tool to compare two strings.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Allocate a memory region shared across processes.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Reporting a numeric comparison failure.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
License along with the GNU C Library; if not, see
<http://www.gnu.org/licenses/>. */
+#include <errno.h>
#include <stdio.h>
#include <support/check.h>
static void
-report (const char *which, const char *expr, long long value, int negative,
+report (const char *which, const char *expr, long long value, int positive,
int size)
{
printf (" %s: ", which);
- if (negative)
- printf ("%lld", value);
- else
+ if (positive)
printf ("%llu", (unsigned long long) value);
+ else
+ printf ("%lld", value);
unsigned long long mask
= (~0ULL) >> (8 * (sizeof (unsigned long long) - size));
printf (" (0x%llx); from: %s\n", (unsigned long long) value & mask, expr);
support_test_compare_failure (const char *file, int line,
const char *left_expr,
long long left_value,
- int left_negative,
+ int left_positive,
int left_size,
const char *right_expr,
long long right_value,
- int right_negative,
+ int right_positive,
int right_size)
{
+ int saved_errno = errno;
support_record_failure ();
if (left_size != right_size)
printf ("%s:%d: numeric comparison failure (widths %d and %d)\n",
file, line, left_size * 8, right_size * 8);
else
printf ("%s:%d: numeric comparison failure\n", file, line);
- report (" left", left_expr, left_value, left_negative, left_size);
- report ("right", right_expr, right_value, right_negative, right_size);
+ report (" left", left_expr, left_value, left_positive, left_size);
+ report ("right", right_expr, right_value, right_positive, right_size);
+ errno = saved_errno;
}
/* Main worker function for the test driver.
- Copyright (C) 1998-2017 Free Software Foundation, Inc.
+ Copyright (C) 1998-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Implementation of the TEST_VERIFY and TEST_VERIFY_EXIT macros.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
#include <support/check.h>
+#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
void
support_test_verify_impl (const char *file, int line, const char *expr)
{
+ int saved_errno = errno;
support_record_failure ();
printf ("error: %s:%d: not true: %s\n", file, line, expr);
+ errno = saved_errno;
}
void
/* Write a string to a file.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Internal weak declarations for temporary file handling.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Temporary file handling for tests.
- Copyright (C) 1998-2017 Free Software Foundation, Inc.
+ Copyright (C) 1998-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Declarations for temporary file handling.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Main function for test programs.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Interfaces for the test driver.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Test entering namespaces.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Test capturing output from a subprocess.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Tests for the support_format_dns_packet function.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
#!/bin/sh
# Test failure recording (with and without --direct).
-# Copyright (C) 2016-2017 Free Software Foundation, Inc.
+# Copyright (C) 2016-2018 Free Software Foundation, Inc.
# This file is part of the GNU C Library.
# The GNU C Library is free software; you can redistribute it and/or
/* Test support_record_failure state sharing.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Basic test for the TEST_COMPARE macro.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
unsigned long long int u63 : 63;
};
+/* Functions which return signed sizes are common, so test that these
+ results can readily checked using TEST_COMPARE. */
+
+static int
+return_ssize_t (void)
+{
+ return 4;
+}
+
+static int
+return_int (void)
+{
+ return 4;
+}
+
+
static int
do_test (void)
{
unsigned short u16 = 3;
TEST_COMPARE (i8, u16);
}
+ TEST_COMPARE (return_ssize_t (), sizeof (char[4]));
+ TEST_COMPARE (return_int (), sizeof (char[4]));
struct bitfield bitfield = { 0 };
TEST_COMPARE (bitfield.i2, bitfield.i3);
/* Test the xreadlink function.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Write a message to standard output.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
#include <support/support.h>
+#include <errno.h>
#include <string.h>
#include <unistd.h>
void
write_message (const char *message)
{
+ int saved_errno = errno;
ssize_t unused __attribute__ ((unused));
unused = write (STDOUT_FILENO, message, strlen (message));
+ errno = saved_errno;
}
/* accept with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* accept4 with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Error-checking wrapper for asprintf.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* bind with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Error-checking wrapper for calloc.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* chroot with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* close with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* connect with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Support functionality for using dlopen/dlclose/dlsym.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Support functionality for using dlopen/dlclose/dlsym.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* dup2 with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* fclose with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* fopen with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* fork with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* ftruncate with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* getsockname with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* listen with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* lseek with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Error-checking wrapper for malloc.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Error-checking wrappers for memstream functions.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Error-checking wrappers for memstream functions.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* mkdir with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* mmap with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* mprotect with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* munmap with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* open64 with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pipe with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* poll with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_attr_destroy with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_attr_init with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_attr_setdetachstate with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_attr_setguardsize with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_attr_setstacksize with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_barrier_destroy with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_barrier_init with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_barrier_wait with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_cancel with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Return value checking for pthread functions, exit variant.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_cond_wait with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_create with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_detach with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_join with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_mutex_consistent with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_mutex_destroy with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_mutex_init with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_mutex_lock with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_mutex_unlock with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_mutexattr_destroy with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_mutexattr_init with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_mutexattr_setprotocol with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_mutexattr_setpshared with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_mutexattr_setrobust with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_mutexattr_settype with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_once with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_rwlock_init with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_rwlock_rdlock with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_rwlock_unlock with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_rwlock_wrlock with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_rwlockattr_init with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_rwlockattr_setkind_np with error checking.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_sigmask with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_spin_lock with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* pthread_spin_unlock with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Error-checking wrapper for raise.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Error-checking, allocating wrapper for readlink.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Error-checking wrapper for realloc.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* recvfrom with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* sendto with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* setsockopt with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Error-checking wrapper for sigaction.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Error-checking wrapper for signal.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Support functionality for using signals.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* socket with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Error-checking wrappers for socket functions.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Error-checking wrappers for stdio functions.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* strdup with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* strndup with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Error-checking wrapper for sysconf.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Support functionality for using threads.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* POSIX-specific extra functions.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* Error-checking wrapper for unlink.
- Copyright (C) 2017 Free Software Foundation, Inc.
+ Copyright (C) 2017-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* waitpid with error checking.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
/* write with error checking and retries.
- Copyright (C) 2016-2017 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or