This is the mail archive of the
glibc-cvs@sourceware.org
mailing list for the glibc project.
GNU C Library master sources branch master updated. glibc-2.26.9000-1241-g99dfbef
- From: sthibaul at sourceware dot org
- To: glibc-cvs at sourceware dot org
- Date: 29 Jan 2018 22:01:11 -0000
- Subject: GNU C Library master sources branch master updated. glibc-2.26.9000-1241-g99dfbef
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".
The branch, master has been updated
via 99dfbef48da238e9a29f83acf3897c2901e5de17 (commit)
via 406e7a0a47110adbf79326c8a0bda5ffac3e0f10 (commit)
via 2aadb70562feae948ed093c86808e7331c5bc6bd (commit)
via ba729de6436ea0a8af3ad80f9555cf3161c7694b (commit)
via 1fd1e27ca7cac9a636cde2c7d19364caf0aaaf33 (commit)
via 2f8902cc7ac60f03fc4ab0646055cf2b3863a8a7 (commit)
from 9a1793289b08339660985cb2baada60debc70bf2 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=99dfbef48da238e9a29f83acf3897c2901e5de17
commit 99dfbef48da238e9a29f83acf3897c2901e5de17
Author: Samuel Thibault <samuel.thibault@ens-lyon.org>
Date: Mon Jan 29 22:56:03 2018 +0100
hurd: Fix comments for FREAD and FWRITE
* bits/fcntl.h: Fix comment for FREAD and FWRITE.
* sysdeps/mach/hurd/bits/fcntl.h: Likewise.
diff --git a/ChangeLog b/ChangeLog
index 579c4f3..64b3943 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -26,6 +26,8 @@
* malloc/malloc.c: Include <assert.h>.
(assert): Do not define.
[!defined NDEBUG] (__assert_fail): Define to __malloc_assert.
+ * bits/fcntl.h: Fix comment for FREAD and FWRITE.
+ * sysdeps/mach/hurd/bits/fcntl.h: Likewise.
2018-01-29 Darius Rad <darius@bluespec.com>
diff --git a/bits/fcntl.h b/bits/fcntl.h
index 7c62303..671c9e6 100644
--- a/bits/fcntl.h
+++ b/bits/fcntl.h
@@ -63,10 +63,7 @@
#endif
#ifdef __USE_MISC
-/* Bits in the file status flags returned by F_GETFL.
- These are all the O_* flags, plus FREAD and FWRITE, which are
- independent bits set by which of O_RDONLY, O_WRONLY, and O_RDWR, was
- given to `open'. */
+/* Flags for TIOCFLUSH. */
# define FREAD 1
# define FWRITE 2
diff --git a/sysdeps/mach/hurd/bits/fcntl.h b/sysdeps/mach/hurd/bits/fcntl.h
index cb8a6ff..2cfaa87 100644
--- a/sysdeps/mach/hurd/bits/fcntl.h
+++ b/sysdeps/mach/hurd/bits/fcntl.h
@@ -135,7 +135,7 @@
#ifdef __USE_MISC
-/* Bits in the file status flags returned by F_GETFL. */
+/* Flags for TIOCFLUSH. */
# define FREAD O_RDONLY
# define FWRITE O_WRONLY
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=406e7a0a47110adbf79326c8a0bda5ffac3e0f10
commit 406e7a0a47110adbf79326c8a0bda5ffac3e0f10
Author: Samuel Thibault <samuel.thibault@ens-lyon.org>
Date: Mon Jan 29 22:49:45 2018 +0100
malloc: Use assert.h's assert macro
This avoids assert definition conflicts if some of the headers used by
malloc.c happens to include assert.h. Malloc still needs a malloc-avoiding
implementation, which we get by redirecting __assert_fail to malloc's
__malloc_assert.
* malloc/malloc.c: Include <assert.h>.
(assert): Do not define.
[!defined NDEBUG] (__assert_fail): Define to __malloc_assert.
diff --git a/ChangeLog b/ChangeLog
index 3060b73..579c4f3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -23,6 +23,9 @@
|| to respect codestyle.
* libio/tst-memstream3.c (_FWRITE): Rename to FWRITE_FUNC.
(do_test_bz20181): Rename accordingly.
+ * malloc/malloc.c: Include <assert.h>.
+ (assert): Do not define.
+ [!defined NDEBUG] (__assert_fail): Define to __malloc_assert.
2018-01-29 Darius Rad <darius@bluespec.com>
diff --git a/malloc/malloc.c b/malloc/malloc.c
index 7889fb1..f8e7250 100644
--- a/malloc/malloc.c
+++ b/malloc/malloc.c
@@ -223,6 +223,7 @@
#include <unistd.h>
#include <stdio.h> /* needed for malloc_stats */
#include <errno.h>
+#include <assert.h>
#include <shlib-compat.h>
@@ -278,13 +279,9 @@
#define MALLOC_DEBUG 0
#endif
-#ifdef NDEBUG
-# define assert(expr) ((void) 0)
-#else
-# define assert(expr) \
- ((expr) \
- ? ((void) 0) \
- : __malloc_assert (#expr, __FILE__, __LINE__, __func__))
+#ifndef NDEBUG
+# define __assert_fail(assertion, file, line, function) \
+ __malloc_assert(assertion, file, line, function)
extern const char *__progname;
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=2aadb70562feae948ed093c86808e7331c5bc6bd
commit 2aadb70562feae948ed093c86808e7331c5bc6bd
Author: Samuel Thibault <samuel.thibault@ens-lyon.org>
Date: Mon Jan 29 22:44:46 2018 +0100
libio: Rename _FWRITE to FWRITE_FUNC
_FWRITE would be in the reserved-namespace.
* libio/tst-memstream3.c (_FWRITE): Rename to FWRITE_FUNC.
(do_test_bz20181): Rename accordingly.
diff --git a/ChangeLog b/ChangeLog
index c86e6a2..3060b73 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -21,6 +21,8 @@
* sysdeps/mach/hurd/i386/libutil.abilist: New file.
* sysdeps/pthread/allocalim.h (__libc_use_alloca): Commute operands of
|| to respect codestyle.
+ * libio/tst-memstream3.c (_FWRITE): Rename to FWRITE_FUNC.
+ (do_test_bz20181): Rename accordingly.
2018-01-29 Darius Rad <darius@bluespec.com>
diff --git a/libio/tst-memstream3.c b/libio/tst-memstream3.c
index df0da5b..bb3300d 100644
--- a/libio/tst-memstream3.c
+++ b/libio/tst-memstream3.c
@@ -29,7 +29,7 @@
# define W(o) o
# define OPEN_MEMSTREAM open_memstream
# define PRINTF printf
-# define _FWRITE fwrite
+# define FWRITE_FUNC fwrite
# define FPUTC fputc
# define STRCMP strcmp
#endif
@@ -114,14 +114,14 @@ do_test_bz20181 (void)
if (fp == NULL)
ERROR_RET1 ("%s failed\n", S(OPEN_MEMSTREAM));
- if ((ret = _FWRITE (W("abc"), 1, 3, fp)) != 3)
- ERROR_RET1 ("%s failed (errno = %d)\n", S(_FWRITE), errno);
+ if ((ret = FWRITE_FUNC (W("abc"), 1, 3, fp)) != 3)
+ ERROR_RET1 ("%s failed (errno = %d)\n", S(FWRITE_FUNC), errno);
if (fseek (fp, 0, SEEK_SET) != 0)
ERROR_RET1 ("fseek failed (errno = %d)\n", errno);
- if (_FWRITE (W("z"), 1, 1, fp) != 1)
- ERROR_RET1 ("%s failed (errno = %d)\n", S(_FWRITE), errno);
+ if (FWRITE_FUNC (W("z"), 1, 1, fp) != 1)
+ ERROR_RET1 ("%s failed (errno = %d)\n", S(FWRITE_FUNC), errno);
if (fflush (fp) != 0)
ERROR_RET1 ("fflush failed (errno = %d)\n", errno);
diff --git a/libio/tst-wmemstream3.c b/libio/tst-wmemstream3.c
index 4edc2b9..f24f0fa 100644
--- a/libio/tst-wmemstream3.c
+++ b/libio/tst-wmemstream3.c
@@ -37,7 +37,7 @@ fwwrite (const void *ptr, size_t size, size_t nmemb, FILE *arq)
#define W(o) L##o
#define OPEN_MEMSTREAM open_wmemstream
#define PRINTF wprintf
-#define _FWRITE fwwrite
+#define FWRITE_FUNC fwwrite
#define FPUTC fputwc
#define STRCMP wcscmp
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=ba729de6436ea0a8af3ad80f9555cf3161c7694b
commit ba729de6436ea0a8af3ad80f9555cf3161c7694b
Author: Samuel Thibault <samuel.thibault@ens-lyon.org>
Date: Mon Jan 29 22:21:46 2018 +0100
allocalim.h: Fix codestyle
* sysdeps/pthread/allocalim.h (__libc_use_alloca): Commute operands of
|| to respect codestyle.
diff --git a/ChangeLog b/ChangeLog
index 6f60102..c86e6a2 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -19,6 +19,8 @@
* sysdeps/mach/hurd/i386/libresolv.abilist: New file.
* sysdeps/mach/hurd/i386/librt.abilist: New file.
* sysdeps/mach/hurd/i386/libutil.abilist: New file.
+ * sysdeps/pthread/allocalim.h (__libc_use_alloca): Commute operands of
+ || to respect codestyle.
2018-01-29 Darius Rad <darius@bluespec.com>
diff --git a/sysdeps/pthread/allocalim.h b/sysdeps/pthread/allocalim.h
index fdae0c2..38faf57 100644
--- a/sysdeps/pthread/allocalim.h
+++ b/sysdeps/pthread/allocalim.h
@@ -24,9 +24,9 @@ extern __always_inline
int
__libc_use_alloca (size_t size)
{
- return (
+ return (__builtin_expect (__libc_alloca_cutoff (size), 1)
#ifdef PTHREAD_STACK_MIN
- __builtin_expect (size <= PTHREAD_STACK_MIN / 4, 1) ||
+ || __builtin_expect (size <= PTHREAD_STACK_MIN / 4, 1)
#endif
- __builtin_expect (__libc_alloca_cutoff (size), 1));
+ );
}
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=1fd1e27ca7cac9a636cde2c7d19364caf0aaaf33
commit 1fd1e27ca7cac9a636cde2c7d19364caf0aaaf33
Author: Samuel Thibault <samuel.thibault@ens-lyon.org>
Date: Mon Jan 29 22:19:14 2018 +0100
hurd: Fix ChangeLog date
diff --git a/ChangeLog b/ChangeLog
index 07e751e..6f60102 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -377,7 +377,7 @@
* sysdeps/mach/hurd/net/if_ppp.h: Do not include non-existing
<net/ppp_defs.h>.
-2008-12-18 Thomas Schwinge <tschwinge@gnu.org>
+2018-01-27 Thomas Schwinge <tschwinge@gnu.org>
* hurd/fcntl-internal.h: New file.
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=2f8902cc7ac60f03fc4ab0646055cf2b3863a8a7
commit 2f8902cc7ac60f03fc4ab0646055cf2b3863a8a7
Author: Samuel Thibault <samuel.thibault@ens-lyon.org>
Date: Mon Jan 29 22:17:11 2018 +0100
hurd: Fix preprocessor indentation
diff --git a/hurd/hurd/fd.h b/hurd/hurd/fd.h
index f43dec5..22dc944 100644
--- a/hurd/hurd/fd.h
+++ b/hurd/hurd/fd.h
@@ -62,7 +62,7 @@ extern struct mutex _hurd_dtable_lock; /* Locks those two variables. */
extern struct hurd_fd *_hurd_fd_get (int fd);
#if defined __USE_EXTERN_INLINES && defined _LIBC
-# if IS_IN (libc)
+# if IS_IN (libc)
_HURD_FD_H_EXTERN_INLINE struct hurd_fd *
_hurd_fd_get (int fd)
{
@@ -95,7 +95,7 @@ _hurd_fd_get (int fd)
return descriptor;
}
-# endif
+# endif
#endif
@@ -281,7 +281,7 @@ extern int _hurd_select (int nfds, struct pollfd *pollfds,
__hurd_file_name_lookup. */
#if defined __USE_EXTERN_INLINES && defined _LIBC
-# if IS_IN (libc)
+# if IS_IN (libc)
_HURD_FD_H_EXTERN_INLINE error_t
__hurd_at_flags (int *at_flags, int *flags)
{
@@ -298,7 +298,7 @@ __hurd_at_flags (int *at_flags, int *flags)
return 0;
}
-# endif
+# endif
#endif
/* Variant of file_name_lookup used in *at function implementations.
diff --git a/hurd/hurd/port.h b/hurd/hurd/port.h
index f1da869..eec85cc 100644
--- a/hurd/hurd/port.h
+++ b/hurd/hurd/port.h
@@ -63,7 +63,7 @@ struct hurd_port
extern void _hurd_port_init (struct hurd_port *port, mach_port_t init);
#if defined __USE_EXTERN_INLINES && defined _LIBC
-# if IS_IN (libc)
+# if IS_IN (libc)
_HURD_PORT_H_EXTERN_INLINE void
_hurd_port_init (struct hurd_port *port, mach_port_t init)
{
@@ -71,7 +71,7 @@ _hurd_port_init (struct hurd_port *port, mach_port_t init)
port->users = NULL;
port->port = init;
}
-# endif
+# endif
#endif
@@ -86,7 +86,7 @@ _hurd_port_locked_get (struct hurd_port *port,
struct hurd_userlink *link);
#if defined __USE_EXTERN_INLINES && defined _LIBC
-# if IS_IN (libc)
+# if IS_IN (libc)
_HURD_PORT_H_EXTERN_INLINE mach_port_t
_hurd_port_locked_get (struct hurd_port *port,
struct hurd_userlink *link)
@@ -102,7 +102,7 @@ _hurd_port_locked_get (struct hurd_port *port,
__spin_unlock (&port->lock);
return result;
}
-# endif
+# endif
#endif
/* Same, but locks PORT first. */
@@ -112,7 +112,7 @@ _hurd_port_get (struct hurd_port *port,
struct hurd_userlink *link);
#if defined __USE_EXTERN_INLINES && defined _LIBC
-# if IS_IN (libc)
+# if IS_IN (libc)
_HURD_PORT_H_EXTERN_INLINE mach_port_t
_hurd_port_get (struct hurd_port *port,
struct hurd_userlink *link)
@@ -124,7 +124,7 @@ _hurd_port_get (struct hurd_port *port,
HURD_CRITICAL_END;
return result;
}
-# endif
+# endif
#endif
@@ -136,7 +136,7 @@ _hurd_port_free (struct hurd_port *port,
mach_port_t used_port);
#if defined __USE_EXTERN_INLINES && defined _LIBC
-# if IS_IN (libc)
+# if IS_IN (libc)
_HURD_PORT_H_EXTERN_INLINE void
_hurd_port_free (struct hurd_port *port,
struct hurd_userlink *link,
@@ -156,7 +156,7 @@ _hurd_port_free (struct hurd_port *port,
if (dealloc)
__mach_port_deallocate (__mach_task_self (), used_port);
}
-# endif
+# endif
#endif
@@ -166,7 +166,7 @@ _hurd_port_free (struct hurd_port *port,
extern void _hurd_port_locked_set (struct hurd_port *port, mach_port_t newport);
#if defined __USE_EXTERN_INLINES && defined _LIBC
-# if IS_IN (libc)
+# if IS_IN (libc)
_HURD_PORT_H_EXTERN_INLINE void
_hurd_port_locked_set (struct hurd_port *port, mach_port_t newport)
{
@@ -177,7 +177,7 @@ _hurd_port_locked_set (struct hurd_port *port, mach_port_t newport)
if (old != MACH_PORT_NULL)
__mach_port_deallocate (__mach_task_self (), old);
}
-# endif
+# endif
#endif
/* Same, but locks PORT first. */
@@ -185,7 +185,7 @@ _hurd_port_locked_set (struct hurd_port *port, mach_port_t newport)
extern void _hurd_port_set (struct hurd_port *port, mach_port_t newport);
#if defined __USE_EXTERN_INLINES && defined _LIBC
-# if IS_IN (libc)
+# if IS_IN (libc)
_HURD_PORT_H_EXTERN_INLINE void
_hurd_port_set (struct hurd_port *port, mach_port_t newport)
{
@@ -194,7 +194,7 @@ _hurd_port_set (struct hurd_port *port, mach_port_t newport)
_hurd_port_locked_set (port, newport);
HURD_CRITICAL_END;
}
-# endif
+# endif
#endif
diff --git a/hurd/hurd/signal.h b/hurd/hurd/signal.h
index 5ee95ac..5323472 100644
--- a/hurd/hurd/signal.h
+++ b/hurd/hurd/signal.h
@@ -43,9 +43,9 @@
#include <hurd/threadvar.h> /* We cache sigstate in a threadvar. */
struct hurd_signal_preemptor; /* <hurd/sigpreempt.h> */
#if defined __USE_EXTERN_INLINES && defined _LIBC
-# if IS_IN (libc) || IS_IN (libpthread)
-# include <sigsetops.h>
-# endif
+# if IS_IN (libc) || IS_IN (libpthread)
+# include <sigsetops.h>
+# endif
#endif
@@ -135,7 +135,7 @@ extern struct hurd_sigstate *_hurd_self_sigstate (void)
#endif
#if defined __USE_EXTERN_INLINES && defined _LIBC
-# if IS_IN (libc)
+# if IS_IN (libc)
_HURD_SIGNAL_H_EXTERN_INLINE struct hurd_sigstate *
_hurd_self_sigstate (void)
{
@@ -145,7 +145,7 @@ _hurd_self_sigstate (void)
*location = _hurd_thread_sigstate (__mach_thread_self ());
return *location;
}
-# endif
+# endif
#endif
/* Thread listening on our message port; also called the "signal thread". */
@@ -176,7 +176,7 @@ extern int _hurd_core_limit;
extern void *_hurd_critical_section_lock (void);
#if defined __USE_EXTERN_INLINES && defined _LIBC
-# if IS_IN (libc)
+# if IS_IN (libc)
_HURD_SIGNAL_H_EXTERN_INLINE void *
_hurd_critical_section_lock (void)
{
@@ -201,13 +201,13 @@ _hurd_critical_section_lock (void)
_hurd_critical_section_unlock to unlock it. */
return ss;
}
-# endif
+# endif
#endif
extern void _hurd_critical_section_unlock (void *our_lock);
#if defined __USE_EXTERN_INLINES && defined _LIBC
-# if IS_IN (libc)
+# if IS_IN (libc)
_HURD_SIGNAL_H_EXTERN_INLINE void
_hurd_critical_section_unlock (void *our_lock)
{
@@ -230,7 +230,7 @@ _hurd_critical_section_unlock (void *our_lock)
__msg_sig_post (_hurd_msgport, 0, 0, __mach_task_self ());
}
}
-# endif
+# endif
#endif
/* Convenient macros for simple uses of critical sections.
diff --git a/hurd/hurd/threadvar.h b/hurd/hurd/threadvar.h
index b5fc29d..9b9b863 100644
--- a/hurd/hurd/threadvar.h
+++ b/hurd/hurd/threadvar.h
@@ -83,7 +83,7 @@ extern unsigned long int *__hurd_threadvar_location_from_sp
(enum __hurd_threadvar_index __index, void *__sp);
#if defined __USE_EXTERN_INLINES && defined _LIBC
-# if IS_IN (libc)
+# if IS_IN (libc)
_HURD_THREADVAR_H_EXTERN_INLINE unsigned long int *
__hurd_threadvar_location_from_sp (enum __hurd_threadvar_index __index,
void *__sp)
@@ -95,7 +95,7 @@ __hurd_threadvar_location_from_sp (enum __hurd_threadvar_index __index,
: (unsigned long int *) ((__stack & __hurd_threadvar_stack_mask) +
__hurd_threadvar_stack_offset))[__index];
}
-# endif
+# endif
#endif
#include <machine-sp.h> /* Define __thread_stack_pointer. */
@@ -111,14 +111,14 @@ __hurd_threadvar_location (enum __hurd_threadvar_index __index) __THROW
__attribute__ ((__const__));
#if defined __USE_EXTERN_INLINES && defined _LIBC
-# if IS_IN (libc)
+# if IS_IN (libc)
_HURD_THREADVAR_H_EXTERN_INLINE unsigned long int *
__hurd_threadvar_location (enum __hurd_threadvar_index __index)
{
return __hurd_threadvar_location_from_sp (__index,
__thread_stack_pointer ());
}
-# endif
+# endif
#endif
diff --git a/hurd/hurd/userlink.h b/hurd/hurd/userlink.h
index 66c0406..fb7cab2 100644
--- a/hurd/hurd/userlink.h
+++ b/hurd/hurd/userlink.h
@@ -81,7 +81,7 @@ _hurd_userlink_link (struct hurd_userlink **chainp,
struct hurd_userlink *link);
#if defined __USE_EXTERN_INLINES && defined _LIBC
-# if IS_IN (libc)
+# if IS_IN (libc)
_HURD_USERLINK_H_EXTERN_INLINE void
_hurd_userlink_link (struct hurd_userlink **chainp,
struct hurd_userlink *link)
@@ -102,7 +102,7 @@ _hurd_userlink_link (struct hurd_userlink **chainp,
link->thread.prevp = thread_chainp;
*thread_chainp = link;
}
-# endif
+# endif
#endif
@@ -112,7 +112,7 @@ _hurd_userlink_link (struct hurd_userlink **chainp,
extern int _hurd_userlink_unlink (struct hurd_userlink *link);
#if defined __USE_EXTERN_INLINES && defined _LIBC
-# if IS_IN (libc)
+# if IS_IN (libc)
_HURD_USERLINK_H_EXTERN_INLINE int
_hurd_userlink_unlink (struct hurd_userlink *link)
{
@@ -135,7 +135,7 @@ _hurd_userlink_unlink (struct hurd_userlink *link)
return dealloc;
}
-# endif
+# endif
#endif
@@ -148,7 +148,7 @@ _hurd_userlink_unlink (struct hurd_userlink *link)
extern int _hurd_userlink_clear (struct hurd_userlink **chainp);
#if defined __USE_EXTERN_INLINES && defined _LIBC
-# if IS_IN (libc)
+# if IS_IN (libc)
_HURD_USERLINK_H_EXTERN_INLINE int
_hurd_userlink_clear (struct hurd_userlink **chainp)
{
@@ -161,7 +161,7 @@ _hurd_userlink_clear (struct hurd_userlink **chainp)
*chainp = NULL;
return 0;
}
-# endif
+# endif
#endif
#endif /* hurd/userlink.h */
-----------------------------------------------------------------------
Summary of changes:
ChangeLog | 11 ++++++++++-
bits/fcntl.h | 5 +----
hurd/hurd/fd.h | 8 ++++----
hurd/hurd/port.h | 24 ++++++++++++------------
hurd/hurd/signal.h | 18 +++++++++---------
hurd/hurd/threadvar.h | 8 ++++----
hurd/hurd/userlink.h | 12 ++++++------
libio/tst-memstream3.c | 10 +++++-----
libio/tst-wmemstream3.c | 2 +-
malloc/malloc.c | 11 ++++-------
sysdeps/mach/hurd/bits/fcntl.h | 2 +-
sysdeps/pthread/allocalim.h | 6 +++---
12 files changed, 60 insertions(+), 57 deletions(-)
hooks/post-receive
--
GNU C Library master sources