]> sourceware.org Git - glibc.git/commitdiff
Update.
authorUlrich Drepper <drepper@redhat.com>
Thu, 26 Feb 2004 01:32:44 +0000 (01:32 +0000)
committerUlrich Drepper <drepper@redhat.com>
Thu, 26 Feb 2004 01:32:44 +0000 (01:32 +0000)
2004-02-24  Arnold D. Robbins  <arnold@skeeve.com>

* posix/regex_internal.c (build_wcs_upper_buffer): Enclose
`offsets_needed' label in `#ifdef _LIBC' to silence `unused label'
compiler warning.

2004-02-24  Nelson H.F. Beebe  <beebe@math.utah.edu>

* posix/regex_internal.c (build_wcs_buffer): Add cast to char* in call
to `wcrtomb'.
* posix/regex_internal.h (bitset_not, bitset_merge, bitset_not_merge,
bitset_mask, re_string_char_size_a, re_string_wchar_at,
re_string_elem_size_at): Change to use prototypes.
(re_string_char_size_at, re_string_wchar_at,
re_string_elem_size_at): Declare as `internal_function'.

ChangeLog
posix/regex_internal.c
posix/regex_internal.h
sysdeps/unix/sysv/linux/sysconf.c

index bd2edacdcd61f046bf1fea346dfe9a7f8891174b..98cf35fef5543c57fac762235922368fc68282ee 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,19 @@
+2004-02-24  Arnold D. Robbins  <arnold@skeeve.com>
+
+       * posix/regex_internal.c (build_wcs_upper_buffer): Enclose
+       `offsets_needed' label in `#ifdef _LIBC' to silence `unused label'
+       compiler warning.
+
+2004-02-24  Nelson H.F. Beebe  <beebe@math.utah.edu>
+
+       * posix/regex_internal.c (build_wcs_buffer): Add cast to char* in call
+       to `wcrtomb'.
+       * posix/regex_internal.h (bitset_not, bitset_merge, bitset_not_merge,
+       bitset_mask, re_string_char_size_a, re_string_wchar_at,
+       re_string_elem_size_at): Change to use prototypes.
+       (re_string_char_size_at, re_string_wchar_at,
+       re_string_elem_size_at): Declare as `internal_function'.
+
 2004-02-25  Ulrich Drepper  <drepper@redhat.com>
 
        * sysdeps/unix/sysv/linux/sysconf.c (__sysconf): Handle
index ed26908ad1478f03edb7baeb34abe90910c8afe2..a3dcfbbb659509a4c44c33872c4980c04adf356c 100644 (file)
@@ -373,7 +373,9 @@ build_wcs_upper_buffer (pstr)
       {
        wchar_t wc;
        const char *p;
+#ifdef _LIBC
 offsets_needed:
+#endif
        remain_len = end_idx - byte_idx;
        prev_st = pstr->cur_state;
        if (BE (pstr->trans != NULL, 0))
@@ -398,7 +400,7 @@ offsets_needed:
                int mbcdlen;
 
                wcu = towupper (wc);
-               mbcdlen = wcrtomb (buf, wcu, &prev_st);
+               mbcdlen = wcrtomb ((char *) buf, wcu, &prev_st);
                if (BE (mbclen == mbcdlen, 1))
                  memcpy (pstr->mbs + byte_idx, buf, mbclen);
                else
index 7ec72946924669750fd86e5b21d3d3a050ddf44c..d7d7d9a8b11b97c26417dc0f1116082f7eb47a84 100644 (file)
@@ -708,8 +708,7 @@ typedef struct
 
 /* Inline functions for bitset operation.  */
 static inline void
-bitset_not (set)
-     bitset set;
+bitset_not (bitset set)
 {
   int bitset_i;
   for (bitset_i = 0; bitset_i < BITSET_UINTS; ++bitset_i)
@@ -717,9 +716,7 @@ bitset_not (set)
 }
 
 static inline void
-bitset_merge (dest, src)
-     bitset dest;
-     const bitset src;
+bitset_merge (bitset dest, const bitset src)
 {
   int bitset_i;
   for (bitset_i = 0; bitset_i < BITSET_UINTS; ++bitset_i)
@@ -727,9 +724,7 @@ bitset_merge (dest, src)
 }
 
 static inline void
-bitset_not_merge (dest, src)
-     bitset dest;
-     const bitset src;
+bitset_not_merge (bitset dest, const bitset src)
 {
   int i;
   for (i = 0; i < BITSET_UINTS; ++i)
@@ -737,9 +732,7 @@ bitset_not_merge (dest, src)
 }
 
 static inline void
-bitset_mask (dest, src)
-     bitset dest;
-     const bitset src;
+bitset_mask (bitset dest, const bitset src)
 {
   int bitset_i;
   for (bitset_i = 0; bitset_i < BITSET_UINTS; ++bitset_i)
@@ -749,9 +742,8 @@ bitset_mask (dest, src)
 #if defined RE_ENABLE_I18N && !defined RE_NO_INTERNAL_PROTOTYPES
 /* Inline functions for re_string.  */
 static inline int
-re_string_char_size_at (pstr, idx)
-     const re_string_t *pstr;
-     int idx;
+internal_function
+re_string_char_size_at (const re_string_t *pstr, int idx)
 {
   int byte_idx;
   if (pstr->mb_cur_max == 1)
@@ -763,9 +755,8 @@ re_string_char_size_at (pstr, idx)
 }
 
 static inline wint_t
-re_string_wchar_at (pstr, idx)
-     const re_string_t *pstr;
-     int idx;
+internal_function
+re_string_wchar_at (const re_string_t *pstr, int idx)
 {
   if (pstr->mb_cur_max == 1)
     return (wint_t) pstr->mbs[idx];
@@ -773,9 +764,8 @@ re_string_wchar_at (pstr, idx)
 }
 
 static int
-re_string_elem_size_at (pstr, idx)
-     const re_string_t *pstr;
-     int idx;
+internal_function
+re_string_elem_size_at (const re_string_t *pstr, int idx)
 {
 #ifdef _LIBC
   const unsigned char *p, *extra;
index 842c8794d07ecc250a93a2e3a0317a3d8f225268..94cba88e9001fbd697d8a84c0233b9fe99380a96 100644 (file)
@@ -51,7 +51,7 @@ __sysconf (int name)
       {
        /* Try to read the information from the /proc/sys/kernel/ngroups_max
           file.  */
-       int fd = __open ("/proc/sys/kernel/ngroups_max", O_RDONLY);
+       int fd = __open_nocancel ("/proc/sys/kernel/ngroups_max", O_RDONLY);
        if (fd != -1)
          {
            /* This is more than enough, the file contains a single
@@ -59,7 +59,7 @@ __sysconf (int name)
            char buf[32];
            long int res = -1l;
 
-           ssize_t n = __read (fd, buf, sizeof (buf) - 1);
+           ssize_t n = __read_nocancel (fd, buf, sizeof (buf) - 1);
            if (n > 0)
              {
                /* Terminate the string.  */
@@ -71,7 +71,7 @@ __sysconf (int name)
                  res = -1l;
              }
 
-           __close (fd);
+           __close_nocancel (fd);
 
            if (res != -1)
              return res;
This page took 0.064231 seconds and 5 git commands to generate.