You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by iv...@apache.org on 2022/11/20 07:14:40 UTC

svn commit: r1905414 [4/8] - in /apr/apr/trunk: atomic/netware/ atomic/os390/ buckets/ build/ crypto/ dbd/ dbd/unsupported/ dbm/ dbm/sdbm/ dso/aix/ dso/beos/ dso/netware/ dso/os2/ dso/os390/ dso/unix/ dso/win32/ encoding/ file_io/netware/ file_io/os2/ ...

Modified: apr/apr/trunk/misc/unix/getopt.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/misc/unix/getopt.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/misc/unix/getopt.c (original)
+++ apr/apr/trunk/misc/unix/getopt.c Sun Nov 20 07:14:38 2022
@@ -68,7 +68,7 @@ APR_DECLARE(apr_status_t) apr_getopt_ini
     return APR_SUCCESS;
 }
 
-APR_DECLARE(apr_status_t) apr_getopt(apr_getopt_t *os, const char *opts, 
+APR_DECLARE(apr_status_t) apr_getopt(apr_getopt_t *os, const char *opts,
                                      char *optch, const char **optarg)
 {
     const char *oli;  /* option letter list index */
@@ -121,7 +121,7 @@ APR_DECLARE(apr_status_t) apr_getopt(apr
                 return (APR_BADARG);
             }
             if (os->errfn) {
-                (os->errfn)(os->errarg, 
+                (os->errfn)(os->errarg,
                             "%s: option requires an argument -- %c\n",
                             apr_filepath_name_get(*os->argv), os->opt);
             }
@@ -182,7 +182,7 @@ static apr_status_t serr(apr_getopt_t *o
                          apr_status_t status)
 {
     if (os->errfn)
-        (os->errfn)(os->errarg, "%s: %s: %s\n", 
+        (os->errfn)(os->errarg, "%s: %s: %s\n",
                     apr_filepath_name_get(*os->argv), err, str);
     return status;
 }
@@ -192,7 +192,7 @@ static apr_status_t cerr(apr_getopt_t *o
                          apr_status_t status)
 {
     if (os->errfn)
-        (os->errfn)(os->errarg, "%s: %s: %c\n", 
+        (os->errfn)(os->errarg, "%s: %s: %c\n",
                     apr_filepath_name_get(*os->argv), err, ch);
     return status;
 }
@@ -251,7 +251,7 @@ APR_DECLARE(apr_status_t) apr_getopt_lon
             if (opts[i].has_arg) {
                 if (p[len] == '=')             /* Argument inline */
                     *optarg = p + len + 1;
-                else { 
+                else {
                     if (os->ind >= os->argc)   /* Argument missing */
                         return serr(os, "missing argument", p - 2, APR_BADARG);
                     else                       /* Argument in next arg */
@@ -270,7 +270,7 @@ APR_DECLARE(apr_status_t) apr_getopt_lon
                 os->ind = os->skip_start;
                 return APR_EOF;
             }
-            else 
+            else
                 if (*p == '\0')                    /* Bare "-" is illegal */
                     return serr(os, "invalid option", p, APR_BADCH);
         }
@@ -292,7 +292,7 @@ APR_DECLARE(apr_status_t) apr_getopt_lon
     if (opts[i].has_arg) {
         if (*p != '\0')                         /* Argument inline */
             *optarg = p;
-        else { 
+        else {
             if (os->ind >= os->argc)           /* Argument missing */
                 return cerr(os, "missing argument", *optch, APR_BADARG);
             else                               /* Argument in next arg */

Modified: apr/apr/trunk/misc/unix/otherchild.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/misc/unix/otherchild.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/misc/unix/otherchild.c (original)
+++ apr/apr/trunk/misc/unix/otherchild.c Sun Nov 20 07:14:38 2022
@@ -65,7 +65,7 @@ APR_DECLARE(void) apr_proc_other_child_r
     ocr->data = data;
     ocr->next = other_children;
     other_children = ocr;
-    apr_pool_cleanup_register(p, ocr->data, other_child_cleanup, 
+    apr_pool_cleanup_register(p, ocr->data, other_child_cleanup,
                               apr_pool_cleanup_null);
 }
 
@@ -107,7 +107,7 @@ APR_DECLARE(apr_status_t) apr_proc_other
 APR_DECLARE(void) apr_proc_other_child_refresh(apr_other_child_rec_t *ocr,
                                                int reason)
 {
-    /* Todo: 
+    /* Todo:
      * Implement code to detect if pipes are still alive.
      */
 #ifdef WIN32
@@ -168,7 +168,7 @@ APR_DECLARE(void) apr_proc_other_child_r
         break;
     }
 #else /* ndef Win32 */
-    pid_t waitret; 
+    pid_t waitret;
     int status;
 
     if (ocr->proc == NULL)

Modified: apr/apr/trunk/misc/unix/rand.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/misc/unix/rand.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/misc/unix/rand.c (original)
+++ apr/apr/trunk/misc/unix/rand.c Sun Nov 20 07:14:38 2022
@@ -103,13 +103,13 @@ APR_DECLARE(apr_status_t) apr_os_uuid_ge
 
     return APR_SUCCESS;
 }
-#endif 
+#endif
 
 #endif /* APR_HAS_OS_UUID */
 
 #if APR_HAS_RANDOM
 
-APR_DECLARE(apr_status_t) apr_generate_random_bytes(unsigned char *buf, 
+APR_DECLARE(apr_status_t) apr_generate_random_bytes(unsigned char *buf,
                                                     apr_size_t length)
 {
 #if defined(HAVE_EGD)
@@ -121,9 +121,9 @@ APR_DECLARE(apr_status_t) apr_generate_r
      *   0xMM (bytes granted) MM bytes
      * 0x02 (read entropy blocking) 0xNN (bytes desired)
      *   [block] NN bytes
-     * 0x03 (write entropy) 0xMM 0xLL (bits of entropy) 0xNN (bytes of data) 
+     * 0x03 (write entropy) 0xMM 0xLL (bits of entropy) 0xNN (bytes of data)
      *      NN bytes
-     * (no response - write only) 
+     * (no response - write only)
      * 0x04 (report PID)
      *   0xMM (length of PID string, not null-terminated) MM chars
      */
@@ -139,7 +139,7 @@ APR_DECLARE(apr_status_t) apr_generate_r
 
     for (egdsockname = egd_sockets; *egdsockname && length > 0; egdsockname++) {
         egd_path_len = strlen(*egdsockname);
-        
+
         if (egd_path_len > sizeof(addr.sun_path)) {
             return APR_EINVAL;
         }
@@ -147,8 +147,8 @@ APR_DECLARE(apr_status_t) apr_generate_r
         memset(&addr, 0, sizeof(struct sockaddr_un));
         addr.sun_family = AF_UNIX;
         memcpy(addr.sun_path, *egdsockname, egd_path_len);
-        egd_addr_len = APR_OFFSETOF(struct sockaddr_un, sun_path) + 
-          egd_path_len; 
+        egd_addr_len = APR_OFFSETOF(struct sockaddr_un, sun_path) +
+          egd_path_len;
 
         egd_socket = socket(PF_UNIX, SOCK_STREAM, 0);
 
@@ -163,7 +163,7 @@ APR_DECLARE(apr_status_t) apr_generate_r
             continue;
         }
 
-        /* EGD can only return 255 bytes of data at a time.  Silly.  */ 
+        /* EGD can only return 255 bytes of data at a time.  Silly.  */
         while (length > 0) {
             apr_ssize_t srv;
             req[0] = 2; /* We'll block for now. */
@@ -182,7 +182,7 @@ APR_DECLARE(apr_status_t) apr_generate_r
                 close(egd_socket);
                 return APR_EGENERAL;
             }
-            
+
             resp_expected = req[1];
             srv = read(egd_socket, resp, resp_expected);
             if (srv == -1) {
@@ -191,12 +191,12 @@ APR_DECLARE(apr_status_t) apr_generate_r
                 close(egd_socket);
                 return bad_errno;
             }
-            
+
             memcpy(curbuf, resp, srv);
             curbuf += srv;
             length -= srv;
         }
-        
+
         shutdown(egd_socket, SHUT_RDWR);
         close(egd_socket);
     }
@@ -242,7 +242,7 @@ APR_DECLARE(apr_status_t) apr_generate_r
         if (fd == -1)
             if ((fd = open(DEV_RANDOM, O_RDONLY)) == -1)
                 return errno;
-        
+
         do {
             rc = read(fd, buf, length);
         } while (rc == -1 && errno == EINTR);
@@ -261,7 +261,7 @@ APR_DECLARE(apr_status_t) apr_generate_r
             length -= rc;
         }
     } while (length > 0);
-    
+
     close(fd);
 
 #elif defined(OS2)

Modified: apr/apr/trunk/misc/unix/start.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/misc/unix/start.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/misc/unix/start.c (original)
+++ apr/apr/trunk/misc/unix/start.c Sun Nov 20 07:14:38 2022
@@ -24,8 +24,8 @@
 #include "apr_arch_internal_time.h"
 
 
-APR_DECLARE(apr_status_t) apr_app_initialize(int *argc, 
-                                             const char * const * *argv, 
+APR_DECLARE(apr_status_t) apr_app_initialize(int *argc,
+                                             const char * const * *argv,
                                              const char * const * *env)
 {
     /* An absolute noop.  At present, only Win32 requires this stub, but it's
@@ -54,7 +54,7 @@ APR_DECLARE(apr_status_t) apr_initialize
 
     if ((status = apr_pool_initialize()) != APR_SUCCESS)
         return status;
-    
+
     if (apr_pool_create(&pool, NULL) != APR_SUCCESS) {
         return APR_ENOPOOL;
     }
@@ -80,7 +80,7 @@ APR_DECLARE_NONSTD(void) apr_terminate(v
         return;
     }
     apr_pool_terminate();
-    
+
 }
 
 APR_DECLARE(void) apr_terminate2(void)

Modified: apr/apr/trunk/misc/win32/apr_app.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/misc/win32/apr_app.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/misc/win32/apr_app.c (original)
+++ apr/apr/trunk/misc/win32/apr_app.c Sun Nov 20 07:14:38 2022
@@ -31,7 +31,7 @@
  *   _dbg_malloc/realloc is used in place of the usual API, in order
  *   to convince the MSVCRT that it created these entities.  If we
  *   do not create them as _CRT_BLOCK entities, the crt will fault
- *   on an assert.  We are not worrying about the crt's locks here, 
+ *   on an assert.  We are not worrying about the crt's locks here,
  *   since we are single threaded [so far].
  */
 

Modified: apr/apr/trunk/misc/win32/internal.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/misc/win32/internal.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/misc/win32/internal.c (original)
+++ apr/apr/trunk/misc/win32/internal.c Sun Nov 20 07:14:38 2022
@@ -29,7 +29,7 @@
  */
 
 
-/* Shared by apr_app.c and start.c 
+/* Shared by apr_app.c and start.c
  *
  * An internal apr function to convert an array of strings (either
  * a counted or NULL terminated list, such as an argv[argc] or env[]
@@ -37,7 +37,7 @@
  * These are allocated from the MSVCRT's _CRT_BLOCK to trick the system
  * into trusting our store.
  */
-int apr_wastrtoastr(char const * const * *retarr, 
+int apr_wastrtoastr(char const * const * *retarr,
                     wchar_t const * const *arr, int args)
 {
     apr_size_t elesize = 0;

Modified: apr/apr/trunk/misc/win32/misc.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/misc/win32/misc.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/misc/win32/misc.c (original)
+++ apr/apr/trunk/misc/win32/misc.c Sun Nov 20 07:14:38 2022
@@ -25,7 +25,7 @@ APR_DECLARE_DATA apr_oslevel_e apr_os_le
 
 apr_status_t apr_get_oslevel(apr_oslevel_e *level)
 {
-    if (apr_os_level == APR_WIN_UNK) 
+    if (apr_os_level == APR_WIN_UNK)
     {
         OSVERSIONINFOEXW oslev;
         oslev.dwOSVersionInfoSize = sizeof(oslev);
@@ -33,7 +33,7 @@ apr_status_t apr_get_oslevel(apr_oslevel
             return apr_get_os_error();
         }
 
-        if (oslev.dwPlatformId == VER_PLATFORM_WIN32_NT) 
+        if (oslev.dwPlatformId == VER_PLATFORM_WIN32_NT)
         {
             unsigned int servpack = oslev.wServicePackMajor;
 
@@ -94,7 +94,7 @@ apr_status_t apr_get_oslevel(apr_oslevel
 }
 
 
-/* This is the helper code to resolve late bound entry points 
+/* This is the helper code to resolve late bound entry points
  * missing from one or more releases of the Win32 API
  */
 
@@ -222,7 +222,7 @@ DWORD apr_wait_for_single_object(HANDLE
 
 /* Declared in include/arch/win32/apr_dbg_win32_handles.h
  */
-APR_DECLARE_NONSTD(HANDLE) apr_dbg_log(char* fn, HANDLE ha, char* fl, int ln, 
+APR_DECLARE_NONSTD(HANDLE) apr_dbg_log(char* fn, HANDLE ha, char* fl, int ln,
                                        int nh, /* HANDLE hv, char *dsc */...)
 {
     static DWORD tlsid = 0xFFFFFFFF;
@@ -232,7 +232,7 @@ APR_DECLARE_NONSTD(HANDLE) apr_dbg_log(c
     long seq;
     DWORD wrote;
     char *sbuf;
-    
+
     seq = (InterlockedIncrement)(&ctr);
 
     if (tlsid == 0xFFFFFFFF) {
@@ -248,7 +248,7 @@ APR_DECLARE_NONSTD(HANDLE) apr_dbg_log(c
             (GetModuleFileNameA)(NULL, sbuf, 250);
             sprintf(strchr(sbuf, '\0'), ".%u",
                     (unsigned int)(GetCurrentProcessId)());
-            fh = (CreateFileA)(sbuf, GENERIC_WRITE, 0, NULL, 
+            fh = (CreateFileA)(sbuf, GENERIC_WRITE, 0, NULL,
                             CREATE_ALWAYS, 0, NULL);
             (InitializeCriticalSection)(&cs);
         }
@@ -261,7 +261,7 @@ APR_DECLARE_NONSTD(HANDLE) apr_dbg_log(c
         (EnterCriticalSection)(&cs);
         (WriteFile)(fh, sbuf, (DWORD)strlen(sbuf), &wrote, NULL);
         (LeaveCriticalSection)(&cs);
-    } 
+    }
     else {
         va_list a;
         va_start(a,nh);
@@ -270,7 +270,7 @@ APR_DECLARE_NONSTD(HANDLE) apr_dbg_log(c
             HANDLE *hv = va_arg(a, HANDLE*);
             char *dsc = va_arg(a, char*);
             if (strcmp(dsc, "Signaled") == 0) {
-                if ((apr_ssize_t)ha >= STATUS_WAIT_0 
+                if ((apr_ssize_t)ha >= STATUS_WAIT_0
                        && (apr_ssize_t)ha < STATUS_ABANDONED_WAIT_0) {
                     hv += (apr_ssize_t)ha;
                 }
@@ -285,7 +285,7 @@ APR_DECLARE_NONSTD(HANDLE) apr_dbg_log(c
             }
             (sprintf)(sbuf, "%p %08x %08x %s(%s) %s:%d\n",
                       *hv, (unsigned int)seq,
-                      (unsigned int)GetCurrentThreadId(), 
+                      (unsigned int)GetCurrentThreadId(),
                       fn, dsc, fl, ln);
             (WriteFile)(fh, sbuf, (DWORD)strlen(sbuf), &wrote, NULL);
         } while (--nh);

Modified: apr/apr/trunk/misc/win32/rand.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/misc/win32/rand.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/misc/win32/rand.c (original)
+++ apr/apr/trunk/misc/win32/rand.c Sun Nov 20 07:14:38 2022
@@ -46,7 +46,7 @@ APR_DECLARE(apr_status_t) apr_generate_r
 
 APR_DECLARE(apr_status_t) apr_os_uuid_get(unsigned char *uuid_data)
 {
-    /* Note: this call doesn't actually require CoInitialize() first 
+    /* Note: this call doesn't actually require CoInitialize() first
      *
      * XXX: we should scramble the bytes or some such to eliminate the
      * possible misuse/abuse since uuid is based on the NIC address, and

Modified: apr/apr/trunk/misc/win32/utf8.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/misc/win32/utf8.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/misc/win32/utf8.c (original)
+++ apr/apr/trunk/misc/win32/utf8.c Sun Nov 20 07:14:38 2022
@@ -27,10 +27,10 @@
  * used as the actual storage conventions by that archicture, these functions
  * exist to transform or validate utf-16 strings into APR's 'char' type
  * convention.  It is left up to the operating system to determine the
- * validitity of the string, e.g. normative forms, in the context of 
- * its native language support.  Other file systems which support filename 
+ * validitity of the string, e.g. normative forms, in the context of
+ * its native language support.  Other file systems which support filename
  * characters of 0x80-0xff but have no explicit requirement for Unicode
- * will find this function useful only for validating the character sequences 
+ * will find this function useful only for validating the character sequences
  * and rejecting poorly encoded utf-8 sequences.
  *
  * len  utf-4 range (hex)  utf-8 octet sequence (binary)
@@ -46,10 +46,10 @@
  * For conversion into utf-16, the 4th form is limited in range to 0010 FFFF,
  * and the final two forms are used only by full utf-32, per RFC 3629;
  *
- *   "Pairs of UCS-2 values between D800 and DFFF (surrogate pairs in 
- *   Unicode parlance), being actually UCS-4 characters transformed 
- *   through UTF-16, need special treatment: the UTF-16 transformation 
- *   must be undone, yielding a UCS-4 character that is then transformed 
+ *   "Pairs of UCS-2 values between D800 and DFFF (surrogate pairs in
+ *   Unicode parlance), being actually UCS-4 characters transformed
+ *   through UTF-16, need special treatment: the UTF-16 transformation
+ *   must be undone, yielding a UCS-4 character that is then transformed
  *   as above."
  *
  * From RFC2781 UTF-16: the compressed ISO 10646 encoding bitmask
@@ -62,7 +62,7 @@
  *   Max U  = 0000 00010000 11111111 11111111
  *
  * Also note ISO/IEC 10646:2014 Clause 9.4: "Because surrogate code points
- * are not UCS scalar values, UTF-32 code units in the range 
+ * are not UCS scalar values, UTF-32 code units in the range
  * 0000 D800-0000 DFFF are ill-formed" for future reference in adding any
  * utf-32 accessor functions.
  *
@@ -73,16 +73,16 @@
  * apr_conv_utf16_to_utf8 out words:sizeof(in) / 2 <= Req <= sizeof(in) * 3 / 2
  */
 
-APR_DECLARE(apr_status_t) apr_conv_utf8_to_utf16(const char *in, 
+APR_DECLARE(apr_status_t) apr_conv_utf8_to_utf16(const char *in,
                                                  apr_size_t *inbytes,
-                                                 apr_wchar_t *out, 
+                                                 apr_wchar_t *out,
                                                  apr_size_t *outwords)
 {
     apr_int64_t newch, mask;
     apr_size_t expect, eating;
     int ch;
-    
-    while (*inbytes && *outwords) 
+
+    while (*inbytes && *outwords)
     {
         ch = (unsigned char)(*in++);
         if (!(ch & 0200)) {
@@ -94,7 +94,7 @@ APR_DECLARE(apr_status_t) apr_conv_utf8_
         }
         else
         {
-            if ((ch & 0300) != 0300) { 
+            if ((ch & 0300) != 0300) {
                 /* Multibyte Continuation is out of place
                  */
                 return APR_EINVAL;
@@ -147,7 +147,7 @@ APR_DECLARE(apr_status_t) apr_conv_utf8_
                 /* Where the boolean (expect > 2) is true, we will need
                  * an extra word for the output.
                  */
-                if (*outwords < (apr_size_t)(expect > 2) + 1) 
+                if (*outwords < (apr_size_t)(expect > 2) + 1)
                     break; /* buffer full */
                 while (expect--)
                 {
@@ -162,17 +162,17 @@ APR_DECLARE(apr_status_t) apr_conv_utf8_
                  *
                  * now we need to fold to utf-16
                  */
-                if (newch < 0x10000) 
+                if (newch < 0x10000)
                 {
                     --*outwords;
                     *(out++) = (apr_wchar_t) newch;
                 }
-                else 
+                else
                 {
                     *outwords -= 2;
                     newch -= 0x10000;
                     *(out++) = (apr_wchar_t) (0xD800 | (newch >> 10));
-                    *(out++) = (apr_wchar_t) (0xDC00 | (newch & 0x03FF));                    
+                    *(out++) = (apr_wchar_t) (0xDC00 | (newch & 0x03FF));
                 }
             }
         }
@@ -183,17 +183,17 @@ APR_DECLARE(apr_status_t) apr_conv_utf8_
     return APR_SUCCESS;
 }
 
-APR_DECLARE(apr_status_t) apr_conv_utf16_to_utf8(const apr_wchar_t *in, 
+APR_DECLARE(apr_status_t) apr_conv_utf16_to_utf8(const apr_wchar_t *in,
                                                  apr_size_t *inwords,
-                                                 char *out, 
+                                                 char *out,
                                                  apr_size_t *outbytes)
 {
     apr_int64_t newch, require;
     apr_size_t need;
     char *invout;
     int ch;
-    
-    while (*inwords && *outbytes) 
+
+    while (*inwords && *outbytes)
     {
         ch = (unsigned short)(*in++);
         if (ch < 0x80)
@@ -202,7 +202,7 @@ APR_DECLARE(apr_status_t) apr_conv_utf16
             --*outbytes;
             *(out++) = (unsigned char) ch;
         }
-        else 
+        else
         {
             if ((ch & 0xFC00) == 0xDC00) {
                 /* Invalid Leading utf-16 Multiword Continuation Character
@@ -259,5 +259,5 @@ APR_DECLARE(apr_status_t) apr_conv_utf16
     /* Buffer full 'errors' aren't errors, the client must inspect both
      * the inwords and outbytes values
      */
-    return APR_SUCCESS;    
+    return APR_SUCCESS;
 }

Modified: apr/apr/trunk/mmap/unix/common.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/mmap/unix/common.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/mmap/unix/common.c (original)
+++ apr/apr/trunk/mmap/unix/common.c Sun Nov 20 07:14:38 2022
@@ -17,7 +17,7 @@
 /* common .c
  * This file has any function that is truly common and platform
  * neutral.  Or at least that's the theory.
- * 
+ *
  * The header files are a problem so there are a few #ifdef's to take
  * care of those.
  *
@@ -35,7 +35,7 @@ APR_DECLARE(apr_status_t) apr_mmap_offse
 {
     if (offset < 0 || (apr_size_t)offset > mmap->size)
         return APR_EINVAL;
-    
+
     (*addr) = (char *) mmap->mm + offset;
     return APR_SUCCESS;
 }

Modified: apr/apr/trunk/mmap/unix/mmap.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/mmap/unix/mmap.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/mmap/unix/mmap.c (original)
+++ apr/apr/trunk/mmap/unix/mmap.c Sun Nov 20 07:14:38 2022
@@ -76,9 +76,9 @@ static apr_status_t mmap_cleanup(void *t
     return errno;
 }
 
-APR_DECLARE(apr_status_t) apr_mmap_create(apr_mmap_t **new, 
-                                          apr_file_t *file, apr_off_t offset, 
-                                          apr_size_t size, apr_int32_t flag, 
+APR_DECLARE(apr_status_t) apr_mmap_create(apr_mmap_t **new,
+                                          apr_file_t *file, apr_off_t offset,
+                                          apr_size_t size, apr_int32_t flag,
                                           apr_pool_t *cont)
 {
     void *mm;
@@ -101,11 +101,11 @@ APR_DECLARE(apr_status_t) apr_mmap_creat
 
     if (size == 0)
         return APR_EINVAL;
-    
+
     if (file == NULL || file->filedes == -1 || file->buffered)
         return APR_EBADF;
     (*new) = (apr_mmap_t *)apr_pcalloc(cont, sizeof(apr_mmap_t));
-    
+
 #ifdef BEOS
     /* XXX: mmap shouldn't really change the seek offset */
     apr_file_seek(file, APR_SET, &offset);
@@ -126,7 +126,7 @@ APR_DECLARE(apr_status_t) apr_mmap_creat
 
     if (aid >= B_NO_ERROR)
         read(file->filedes, mm, size);
-    
+
     (*new)->area = aid;
 #else
 

Modified: apr/apr/trunk/mmap/win32/mmap.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/mmap/win32/mmap.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/mmap/win32/mmap.c (original)
+++ apr/apr/trunk/mmap/win32/mmap.c Sun Nov 20 07:14:38 2022
@@ -51,7 +51,7 @@ static apr_status_t mmap_cleanup(void *t
         }
         mm->mv = NULL;
     }
-    if (mm->mhandle) 
+    if (mm->mhandle)
     {
         if (!CloseHandle(mm->mhandle))
         {
@@ -80,7 +80,7 @@ APR_DECLARE(apr_status_t) apr_mmap_creat
 
     if (size == 0)
         return APR_EINVAL;
-    
+
     if (flag & APR_MMAP_WRITE)
         fmaccess |= PAGE_READWRITE;
     else if (flag & APR_MMAP_READ)
@@ -100,14 +100,14 @@ APR_DECLARE(apr_status_t) apr_mmap_creat
         SYSTEM_INFO si;
         GetSystemInfo(&si);
         memblock = si.dwAllocationGranularity;
-    }   
-    
+    }
+
     *new = apr_pcalloc(cont, sizeof(apr_mmap_t));
     pstart = (offset / memblock) * memblock;
     poffset = offset - pstart;
     psize = (apr_size_t)poffset + size;
     /* The size of the CreateFileMapping object is the current size
-     * of the size of the mmap object (e.g. file size), not the size 
+     * of the size of the mmap object (e.g. file size), not the size
      * of the mapped region!
      */
 

Modified: apr/apr/trunk/network_io/beos/sendrecv.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/network_io/beos/sendrecv.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/network_io/beos/sendrecv.c (original)
+++ apr/apr/trunk/network_io/beos/sendrecv.c Sun Nov 20 07:14:38 2022
@@ -40,7 +40,7 @@ static apr_status_t wait_for_io_or_timeo
         }
         srv = select(sock->socketdes + 1,
             for_read ? &fdset : NULL,
-            for_read ? NULL : &fdset, 
+            for_read ? NULL : &fdset,
             NULL,
             tvptr);
             /* TODO - timeout should be smaller on repeats of this loop */
@@ -61,15 +61,15 @@ APR_DECLARE(apr_status_t) apr_socket_sen
                                           apr_size_t *len)
 {
     apr_ssize_t rv;
-	
+
     do {
         rv = send(sock->socketdes, buf, (*len), 0);
     } while (rv == -1 && errno == EINTR);
 
     if (rv == -1 && errno == EWOULDBLOCK && sock->timeout > 0) {
         apr_int32_t snooze_val = SEND_WAIT;
-        apr_int32_t zzz = 0;  
-        
+        apr_int32_t zzz = 0;
+
         do {
             rv = send(sock->socketdes, buf, (*len), 0);
             if (rv == -1 && errno == EWOULDBLOCK){
@@ -91,11 +91,11 @@ APR_DECLARE(apr_status_t) apr_socket_sen
     return APR_SUCCESS;
 }
 
-APR_DECLARE(apr_status_t) apr_socket_recv(apr_socket_t *sock, char *buf, 
+APR_DECLARE(apr_status_t) apr_socket_recv(apr_socket_t *sock, char *buf,
                                           apr_size_t *len)
 {
     apr_ssize_t rv;
-   
+
     do {
         rv = recv(sock->socketdes, buf, (*len), 0);
     } while (rv == -1 && errno == EINTR);
@@ -124,7 +124,7 @@ APR_DECLARE(apr_status_t) apr_socket_rec
 
 /* BeOS doesn't have writev for sockets so we use the following instead...
  */
-APR_DECLARE(apr_status_t) apr_socket_sendv(apr_socket_t * sock, 
+APR_DECLARE(apr_status_t) apr_socket_sendv(apr_socket_t * sock,
                                            const struct iovec *vec,
                                            apr_int32_t nvec, apr_size_t *len)
 {
@@ -132,7 +132,7 @@ APR_DECLARE(apr_status_t) apr_socket_sen
     return apr_socket_send(sock, vec[0].iov_base, len);
 }
 
-APR_DECLARE(apr_status_t) apr_socket_sendto(apr_socket_t *sock, 
+APR_DECLARE(apr_status_t) apr_socket_sendto(apr_socket_t *sock,
                                             apr_sockaddr_t *where,
                                             apr_int32_t flags, const char *buf,
                                             apr_size_t *len)
@@ -203,9 +203,9 @@ APR_DECLARE(apr_status_t) apr_socket_rec
         (*len) = 0;
         return errno;
     }
-	
+
     from->port = ntohs(from->sa.sin.sin_port);
-	
+
     (*len) = rv;
     if (rv == 0)
         return APR_EOF;

Modified: apr/apr/trunk/network_io/os2/sendrecv.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/network_io/os2/sendrecv.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/network_io/os2/sendrecv.c (original)
+++ apr/apr/trunk/network_io/os2/sendrecv.c Sun Nov 20 07:14:38 2022
@@ -105,8 +105,8 @@ APR_DECLARE(apr_status_t) apr_socket_rec
 
 
 
-APR_DECLARE(apr_status_t) apr_socket_sendv(apr_socket_t *sock, 
-                                           const struct iovec *vec, 
+APR_DECLARE(apr_status_t) apr_socket_sendv(apr_socket_t *sock,
+                                           const struct iovec *vec,
                                            apr_int32_t nvec, apr_size_t *len)
 {
     apr_status_t rv;
@@ -159,7 +159,7 @@ APR_DECLARE(apr_status_t) apr_socket_sen
 APR_DECLARE(apr_status_t) apr_socket_wait(apr_socket_t *sock, apr_wait_type_t direction)
 {
     int pollsocket = sock->socketdes;
-    int wait_rc = select(&pollsocket, direction == APR_WAIT_READ, 
+    int wait_rc = select(&pollsocket, direction == APR_WAIT_READ,
                          direction == APR_WAIT_WRITE, 0, sock->timeout / 1000);
 
     if (wait_rc == 0) {

Modified: apr/apr/trunk/network_io/os2/sendrecv_udp.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/network_io/os2/sendrecv_udp.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/network_io/os2/sendrecv_udp.c (original)
+++ apr/apr/trunk/network_io/os2/sendrecv_udp.c Sun Nov 20 07:14:38 2022
@@ -48,7 +48,7 @@ APR_DECLARE(apr_status_t) apr_socket_sen
     int serrno;
 
     do {
-        rv = sendto(sock->socketdes, buf, (*len), flags, 
+        rv = sendto(sock->socketdes, buf, (*len), flags,
                     (struct sockaddr*)&where->sa,
                     where->salen);
 

Modified: apr/apr/trunk/network_io/os2/sockets.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/network_io/os2/sockets.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/network_io/os2/sockets.c (original)
+++ apr/apr/trunk/network_io/os2/sockets.c Sun Nov 20 07:14:38 2022
@@ -115,13 +115,13 @@ APR_DECLARE(apr_status_t) apr_socket_cre
 
     (*new)->timeout = -1;
     (*new)->nonblock = FALSE;
-    apr_pool_cleanup_register((*new)->pool, (void *)(*new), 
+    apr_pool_cleanup_register((*new)->pool, (void *)(*new),
                         socket_cleanup, apr_pool_cleanup_null);
 
     return APR_SUCCESS;
-} 
+}
 
-APR_DECLARE(apr_status_t) apr_socket_shutdown(apr_socket_t *thesocket, 
+APR_DECLARE(apr_status_t) apr_socket_shutdown(apr_socket_t *thesocket,
                                               apr_shutdown_how_e how)
 {
     if (shutdown(thesocket->socketdes, how) == 0) {
@@ -141,7 +141,7 @@ APR_DECLARE(apr_status_t) apr_socket_clo
 APR_DECLARE(apr_status_t) apr_socket_bind(apr_socket_t *sock,
                                           apr_sockaddr_t *sa)
 {
-    if (bind(sock->socketdes, 
+    if (bind(sock->socketdes,
              (struct sockaddr *)&sa->sa,
              sa->salen) == -1)
         return APR_FROM_OS_ERROR(sock_errno());
@@ -155,7 +155,7 @@ APR_DECLARE(apr_status_t) apr_socket_bin
     }
 }
 
-APR_DECLARE(apr_status_t) apr_socket_listen(apr_socket_t *sock, 
+APR_DECLARE(apr_status_t) apr_socket_listen(apr_socket_t *sock,
                                             apr_int32_t backlog)
 {
     if (listen(sock->socketdes, backlog) == -1)
@@ -164,7 +164,7 @@ APR_DECLARE(apr_status_t) apr_socket_lis
         return APR_SUCCESS;
 }
 
-APR_DECLARE(apr_status_t) apr_socket_accept(apr_socket_t **new, 
+APR_DECLARE(apr_status_t) apr_socket_accept(apr_socket_t **new,
                                             apr_socket_t *sock,
                                             apr_pool_t *connection_context)
 {
@@ -174,7 +174,7 @@ APR_DECLARE(apr_status_t) apr_socket_acc
     (*new)->timeout = -1;
     (*new)->nonblock = FALSE;
 
-    (*new)->socketdes = accept(sock->socketdes, 
+    (*new)->socketdes = accept(sock->socketdes,
                                (struct sockaddr *)&(*new)->remote_addr->sa,
                                &(*new)->remote_addr->salen);
 
@@ -191,7 +191,7 @@ APR_DECLARE(apr_status_t) apr_socket_acc
         (*new)->local_addr->ipaddr_ptr = &(*new)->local_addr->sa.sin.sin_addr;
     }
 
-    apr_pool_cleanup_register((*new)->pool, (void *)(*new), 
+    apr_pool_cleanup_register((*new)->pool, (void *)(*new),
                         socket_cleanup, apr_pool_cleanup_null);
     return APR_SUCCESS;
 }
@@ -199,14 +199,14 @@ APR_DECLARE(apr_status_t) apr_socket_acc
 APR_DECLARE(apr_status_t) apr_socket_connect(apr_socket_t *sock,
                                              apr_sockaddr_t *sa)
 {
-    if ((connect(sock->socketdes, (struct sockaddr *)&sa->sa.sin, 
+    if ((connect(sock->socketdes, (struct sockaddr *)&sa->sa.sin,
                  sa->salen) < 0) &&
         (sock_errno() != SOCEINPROGRESS)) {
         return APR_FROM_OS_ERROR(sock_errno());
     }
     else {
         int namelen = sizeof(sock->local_addr->sa.sin);
-        getsockname(sock->socketdes, (struct sockaddr *)&sock->local_addr->sa.sin, 
+        getsockname(sock->socketdes, (struct sockaddr *)&sock->local_addr->sa.sin,
                     &namelen);
         sock->remote_addr = sa;
         return APR_SUCCESS;
@@ -262,8 +262,8 @@ APR_DECLARE(apr_status_t) apr_os_sock_ge
     return APR_SUCCESS;
 }
 
-APR_DECLARE(apr_status_t) apr_os_sock_make(apr_socket_t **apr_sock, 
-                                           apr_os_sock_info_t *os_sock_info, 
+APR_DECLARE(apr_status_t) apr_os_sock_make(apr_socket_t **apr_sock,
+                                           apr_os_sock_info_t *os_sock_info,
                                            apr_pool_t *cont)
 {
     alloc_socket(apr_sock, cont);
@@ -271,8 +271,8 @@ APR_DECLARE(apr_status_t) apr_os_sock_ma
     (*apr_sock)->timeout = -1;
     (*apr_sock)->socketdes = *os_sock_info->os_sock;
     if (os_sock_info->local) {
-        memcpy(&(*apr_sock)->local_addr->sa.sin, 
-               os_sock_info->local, 
+        memcpy(&(*apr_sock)->local_addr->sa.sin,
+               os_sock_info->local,
                (*apr_sock)->local_addr->salen);
         /* XXX IPv6 - this assumes sin_port and sin6_port at same offset */
         (*apr_sock)->local_addr->port = ntohs((*apr_sock)->local_addr->sa.sin.sin_port);
@@ -281,7 +281,7 @@ APR_DECLARE(apr_status_t) apr_os_sock_ma
         (*apr_sock)->local_port_unknown = (*apr_sock)->local_interface_unknown = 1;
     }
     if (os_sock_info->remote) {
-        memcpy(&(*apr_sock)->remote_addr->sa.sin, 
+        memcpy(&(*apr_sock)->remote_addr->sa.sin,
                os_sock_info->remote,
                (*apr_sock)->remote_addr->salen);
         /* XXX IPv6 - this assumes sin_port and sin6_port at same offset */
@@ -290,8 +290,8 @@ APR_DECLARE(apr_status_t) apr_os_sock_ma
     else {
         (*apr_sock)->remote_addr_unknown = 1;
     }
-        
-    apr_pool_cleanup_register((*apr_sock)->pool, (void *)(*apr_sock), 
+
+    apr_pool_cleanup_register((*apr_sock)->pool, (void *)(*apr_sock),
                         socket_cleanup, apr_pool_cleanup_null);
 
     return APR_SUCCESS;

Modified: apr/apr/trunk/network_io/os2/sockopt.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/network_io/os2/sockopt.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/network_io/os2/sockopt.c (original)
+++ apr/apr/trunk/network_io/os2/sockopt.c Sun Nov 20 07:14:38 2022
@@ -29,7 +29,7 @@
 #include <sys/so_ioctl.h>
 
 
-APR_DECLARE(apr_status_t) apr_socket_timeout_set(apr_socket_t *sock, 
+APR_DECLARE(apr_status_t) apr_socket_timeout_set(apr_socket_t *sock,
                                                  apr_interval_time_t t)
 {
     apr_status_t rv = APR_SUCCESS;
@@ -44,14 +44,14 @@ APR_DECLARE(apr_status_t) apr_socket_tim
     }
     else if (t != 0 && sock->timeout == 0) {
         rv = apr_socket_opt_set(sock, APR_SO_NONBLOCK, 0);
-    } 
+    }
 
     sock->timeout = t;
     return rv;
 }
 
 
-APR_DECLARE(apr_status_t) apr_socket_opt_set(apr_socket_t *sock, 
+APR_DECLARE(apr_status_t) apr_socket_opt_set(apr_socket_t *sock,
                                              apr_int32_t opt, apr_int32_t on)
 {
     int one;
@@ -110,7 +110,7 @@ APR_DECLARE(apr_status_t) apr_socket_opt
 }
 
 
-APR_DECLARE(apr_status_t) apr_socket_timeout_get(apr_socket_t *sock, 
+APR_DECLARE(apr_status_t) apr_socket_timeout_get(apr_socket_t *sock,
                                                  apr_interval_time_t *t)
 {
     *t = sock->timeout;
@@ -118,7 +118,7 @@ APR_DECLARE(apr_status_t) apr_socket_tim
 }
 
 
-APR_DECLARE(apr_status_t) apr_socket_opt_get(apr_socket_t *sock, 
+APR_DECLARE(apr_status_t) apr_socket_opt_get(apr_socket_t *sock,
                                              apr_int32_t opt, apr_int32_t *on)
 {
     switch(opt) {
@@ -143,7 +143,7 @@ APR_DECLARE(apr_status_t) apr_socket_atm
 }
 
 
-APR_DECLARE(apr_status_t) apr_gethostname(char *buf, apr_int32_t len, 
+APR_DECLARE(apr_status_t) apr_gethostname(char *buf, apr_int32_t len,
                                           apr_pool_t *cont)
 {
     if (gethostname(buf, len) == -1) {

Modified: apr/apr/trunk/network_io/unix/multicast.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/network_io/unix/multicast.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/network_io/unix/multicast.c (original)
+++ apr/apr/trunk/network_io/unix/multicast.c Sun Nov 20 07:14:38 2022
@@ -47,15 +47,15 @@ static void fill_mip_v4(struct ip_mreq *
 static unsigned int find_if_index(const apr_sockaddr_t *iface)
 {
     unsigned int index = 0;
-#if defined(HAVE_GETIFADDRS) && APR_HAVE_IFADDRS_H && APR_HAVE_IPV6 
+#if defined(HAVE_GETIFADDRS) && APR_HAVE_IFADDRS_H && APR_HAVE_IPV6
     struct ifaddrs *ifp, *ifs;
 
     /**
-     * TODO: getifaddrs is only portable to *BSD and OS X. Using ioctl 
+     * TODO: getifaddrs is only portable to *BSD and OS X. Using ioctl
      *       and SIOCGIFCONF is needed for Linux/Solaris support.
-     *       
-     *       There is a wrapper that takes the messy ioctl interface into 
-     *       getifaddrs. The license is acceptable, but, It is a fairly large 
+     *
+     *       There is a wrapper that takes the messy ioctl interface into
+     *       getifaddrs. The license is acceptable, but, It is a fairly large
      *       chunk of code.
      */
     if (getifaddrs(&ifs) != 0) {
@@ -129,7 +129,7 @@ static apr_status_t do_mcast(int type, a
 #ifdef GROUP_FILTER_SIZE
         if (sock_is_ipv4(sock)) {
             ip_proto = IPPROTO_IP;
-        } 
+        }
 #if APR_HAVE_IPV6
         else if (sock_is_ipv6(sock)) {
             ip_proto = IPPROTO_IPV6;

Modified: apr/apr/trunk/network_io/unix/sendrecv.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/network_io/unix/sendrecv.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/network_io/unix/sendrecv.c (original)
+++ apr/apr/trunk/network_io/unix/sendrecv.c Sun Nov 20 07:14:38 2022
@@ -27,11 +27,11 @@
 #include <osreldate.h>
 #endif
 
-apr_status_t apr_socket_send(apr_socket_t *sock, const char *buf, 
+apr_status_t apr_socket_send(apr_socket_t *sock, const char *buf,
                              apr_size_t *len)
 {
     apr_ssize_t rv;
-    
+
     if (sock->options & APR_INCOMPLETE_WRITE) {
         sock->options &= ~APR_INCOMPLETE_WRITE;
         goto do_select;
@@ -41,7 +41,7 @@ apr_status_t apr_socket_send(apr_socket_
         rv = write(sock->socketdes, buf, (*len));
     } while (rv == -1 && errno == EINTR);
 
-    while (rv == -1 && (errno == EAGAIN || errno == EWOULDBLOCK) 
+    while (rv == -1 && (errno == EAGAIN || errno == EWOULDBLOCK)
                     && (sock->timeout > 0)) {
         apr_status_t arv;
 do_select:
@@ -116,8 +116,8 @@ apr_status_t apr_socket_sendto(apr_socke
     apr_ssize_t rv;
 
     do {
-        rv = sendto(sock->socketdes, buf, (*len), flags, 
-                    (const struct sockaddr*)&where->sa, 
+        rv = sendto(sock->socketdes, buf, (*len), flags,
+                    (const struct sockaddr*)&where->sa,
                     where->salen);
     } while (rv == -1 && errno == EINTR);
 
@@ -144,15 +144,15 @@ apr_status_t apr_socket_sendto(apr_socke
 }
 
 apr_status_t apr_socket_recvfrom(apr_sockaddr_t *from, apr_socket_t *sock,
-                                 apr_int32_t flags, char *buf, 
+                                 apr_int32_t flags, char *buf,
                                  apr_size_t *len)
 {
     apr_ssize_t rv;
-    
+
     from->salen = sizeof(from->sa);
 
     do {
-        rv = recvfrom(sock->socketdes, buf, (*len), flags, 
+        rv = recvfrom(sock->socketdes, buf, (*len), flags,
                       (struct sockaddr*)&from->sa, &from->salen);
     } while (rv == -1 && errno == EINTR);
 
@@ -207,7 +207,7 @@ apr_status_t apr_socket_sendv(apr_socket
         rv = writev(sock->socketdes, vec, nvec);
     } while (rv == -1 && errno == EINTR);
 
-    while ((rv == -1) && (errno == EAGAIN || errno == EWOULDBLOCK) 
+    while ((rv == -1) && (errno == EAGAIN || errno == EWOULDBLOCK)
                       && (sock->timeout > 0)) {
         apr_status_t arv;
 do_select:
@@ -279,12 +279,12 @@ apr_status_t apr_socket_sendfile(apr_soc
     /* 64-bit apr_off_t but no sendfile64(): fail if trying to send
      * past the 2Gb limit. */
     off_t off;
-    
+
     if ((apr_int64_t)*offset + bytes_to_send > INT_MAX) {
         *len = 0;
         return EINVAL;
     }
-    
+
     off = *offset;
 
 #else
@@ -325,8 +325,8 @@ apr_status_t apr_socket_sendfile(apr_soc
             return arv;
         }
 
-        /* If this was a partial write and we aren't doing timeouts, 
-         * return now with the partial byte count; this is a non-blocking 
+        /* If this was a partial write and we aren't doing timeouts,
+         * return now with the partial byte count; this is a non-blocking
          * socket.
          */
         total_hdrbytes = 0;
@@ -353,7 +353,7 @@ apr_status_t apr_socket_sendfile(apr_soc
                       bytes_to_send);   /* number of bytes to send */
     } while (rv == -1 && errno == EINTR);
 
-    while ((rv == -1) && (errno == EAGAIN || errno == EWOULDBLOCK) 
+    while ((rv == -1) && (errno == EAGAIN || errno == EWOULDBLOCK)
                       && (sock->timeout > 0)) {
 do_select:
         arv = apr_wait_for_io_or_timeout(NULL, sock, 0);
@@ -388,8 +388,8 @@ do_select:
             arv = APR_SUCCESS;
         }
         if (rv > 0) {
-                
-            /* If this was a partial write, return now with the 
+
+            /* If this was a partial write, return now with the
              * partial byte count;  this is a non-blocking socket.
              */
 
@@ -400,7 +400,7 @@ do_select:
         }
         else {
             /* If the file got smaller mid-request, eventually the offset
-             * becomes equal to the new file size and the kernel returns 0.  
+             * becomes equal to the new file size and the kernel returns 0.
              * Make this an error so the caller knows to log something and
              * exit.
              */
@@ -446,8 +446,8 @@ apr_status_t apr_socket_sendfile(apr_soc
         hdtr = &no_hdtr;
     }
 
-    /* OS X can send the headers/footers as part of the system call, 
-     * but how it counts bytes isn't documented properly. We use 
+    /* OS X can send the headers/footers as part of the system call,
+     * but how it counts bytes isn't documented properly. We use
      * apr_socket_sendv() instead.
      */
      if (hdtr->numheaders > 0) {
@@ -566,9 +566,9 @@ apr_status_t apr_socket_sendfile(apr_soc
 #if defined(__FreeBSD_version) && __FreeBSD_version < 460001
     else if (hdtr->numheaders) {
 
-        /* On early versions of FreeBSD sendfile, the number of bytes to send 
-         * must include the length of the headers.  Don't look at the man page 
-         * for this :(  Instead, look at the logic in 
+        /* On early versions of FreeBSD sendfile, the number of bytes to send
+         * must include the length of the headers.  Don't look at the man page
+         * for this :(  Instead, look at the logic in
          * src/sys/kern/uipc_syscalls::sendfile().
          *
          * This was fixed in the middle of 4.6-STABLE
@@ -635,7 +635,7 @@ apr_status_t apr_socket_sendfile(apr_soc
                 }
                 *len += nbytes;
             }
-        }    
+        }
         else {
             /* just trailer bytes... use writev()
              */
@@ -673,7 +673,7 @@ apr_status_t apr_socket_sendfile(apr_soc
 /* ssize_t sendfile(int s, int fd, off_t offset, size_t nbytes,
  *                  const struct iovec *hdtrl, int flags);
  *
- * nbytes is the number of bytes to send just from the file; as with FreeBSD, 
+ * nbytes is the number of bytes to send just from the file; as with FreeBSD,
  * if nbytes == 0, the rest of the file (from offset) is sent
  */
 
@@ -728,7 +728,7 @@ apr_status_t apr_socket_sendfile(apr_soc
         headerlen = 0;
         for (i = 0; i < hdtr->numheaders; i++) {
             headerlen += hdtr->headers[i].iov_len;
-        }  
+        }
 
         /* XXX:  BUHHH? wow, what a memory leak! */
         headerbuf = hdtrarray[0].iov_base = apr_palloc(sock->pool, headerlen);
@@ -780,7 +780,7 @@ apr_status_t apr_socket_sendfile(apr_soc
         }
     } while (rc == -1 && errno == EINTR);
 
-    while ((rc == -1) && (errno == EAGAIN || errno == EWOULDBLOCK) 
+    while ((rc == -1) && (errno == EAGAIN || errno == EWOULDBLOCK)
                       && (sock->timeout > 0)) {
         apr_status_t arv = apr_wait_for_io_or_timeout(NULL, sock, 0);
 
@@ -927,7 +927,7 @@ apr_status_t apr_socket_sendfile(apr_soc
                        flags);             /* flags */
     } while (rv == -1 && errno == EINTR);
 
-    while ((rv == -1) && (errno == EAGAIN || errno == EWOULDBLOCK) 
+    while ((rv == -1) && (errno == EAGAIN || errno == EWOULDBLOCK)
                       && (sock->timeout > 0)) {
 do_select:
         arv = apr_wait_for_io_or_timeout(NULL, sock, 0);
@@ -957,7 +957,7 @@ do_select:
     }
 
     if ((sock->timeout > 0)
-          && (parms.bytes_sent 
+          && (parms.bytes_sent
                 < (parms.file_bytes + parms.header_length + parms.trailer_length))) {
         sock->options |= APR_INCOMPLETE_WRITE;
     }
@@ -970,7 +970,7 @@ do_select:
  * hang the machine and the only way to fix it is a reboot.
  */
 #elif defined(HAVE_SENDFILEV)
-/* Solaris 8's sendfilev() interface 
+/* Solaris 8's sendfilev() interface
  *
  * SFV_FD_SELF refers to our memory space.
  *
@@ -1027,7 +1027,7 @@ apr_status_t apr_socket_sendfile(apr_soc
         sfv[curvec].sfv_fd = file->filedes;
         sfv[curvec].sfv_flag = 0;
         sfv[curvec].sfv_off = *offset;
-        sfv[curvec].sfv_len = *len; 
+        sfv[curvec].sfv_len = *len;
         requested_len += sfv[curvec].sfv_len;
 
         curvec++;
@@ -1056,14 +1056,14 @@ apr_status_t apr_socket_sendfile(apr_soc
             return arv;
         }
     }
- 
+
     /* Actually do the sendfilev
      *
      * Solaris may return -1/EAGAIN even if it sent bytes on a non-block sock.
      *
-     * If no bytes were originally sent (nbytes == 0) and we are on a TIMEOUT 
-     * socket (which as far as the OS is concerned is a non-blocking socket), 
-     * we want to retry after waiting for the other side to read the data (as 
+     * If no bytes were originally sent (nbytes == 0) and we are on a TIMEOUT
+     * socket (which as far as the OS is concerned is a non-blocking socket),
+     * we want to retry after waiting for the other side to read the data (as
      * determined by poll).  Once it is clear to send, we want to retry
      * sending the sendfilevec_t once more.
      */
@@ -1087,7 +1087,7 @@ apr_status_t apr_socket_sendfile(apr_soc
                     return t;
                 }
 
-                arv = 1; 
+                arv = 1;
                 repeat = 1;
             }
         }
@@ -1115,7 +1115,7 @@ apr_status_t apr_socket_sendfile(apr_soc
 }
 #else
 #error APR has detected sendfile on your system, but nobody has written a
-#error version of it for APR yet.  To get past this, either write 
+#error version of it for APR yet.  To get past this, either write
 #error apr_socket_sendfile or change APR_HAS_SENDFILE in apr.h to 0.
 #endif /* __linux__, __FreeBSD__, __DragonFly__, __HPUX__, _AIX, __MVS__,
       Tru64/OSF1 */

Modified: apr/apr/trunk/network_io/unix/sockaddr.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/network_io/unix/sockaddr.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/network_io/unix/sockaddr.c (original)
+++ apr/apr/trunk/network_io/unix/sockaddr.c Sun Nov 20 07:14:38 2022
@@ -122,7 +122,7 @@ APR_DECLARE(apr_status_t) apr_sockaddr_i
     }
 
 #if APR_HAVE_IPV6
-    if (sockaddr->family == AF_INET6 
+    if (sockaddr->family == AF_INET6
         && IN6_IS_ADDR_V4MAPPED((struct in6_addr *)sockaddr->ipaddr_ptr)
         && buflen > strlen("::ffff:")) {
         /* This is an IPv4-mapped IPv6 address; drop the leading
@@ -153,7 +153,7 @@ APR_DECLARE(apr_status_t) apr_sockaddr_i
             *p++ = '%';
             memcpy(p, scbuf, strlen(scbuf) + 1);
         }
-    }    
+    }
 #endif /* HAVE_IF_INDEXTONAME */
 #endif /* APR_HAVE_IPV6 */
 
@@ -283,9 +283,9 @@ APR_DECLARE(apr_status_t) apr_parse_addr
     /* now handle the hostname */
     addrlen = lastchar - str + 1;
 
-/* XXX we don't really have to require APR_HAVE_IPV6 for this; 
+/* XXX we don't really have to require APR_HAVE_IPV6 for this;
  * just pass char[] for ipaddr (so we don't depend on struct in6_addr)
- * and always define APR_INET6 
+ * and always define APR_INET6
  */
 #if APR_HAVE_IPV6
     if (*str == '[') {
@@ -320,10 +320,10 @@ APR_DECLARE(apr_status_t) apr_parse_addr
             return APR_EINVAL;
         }
     }
-    else 
+    else
 #endif
     {
-        /* XXX If '%' is not a valid char in a DNS name, we *could* check 
+        /* XXX If '%' is not a valid char in a DNS name, we *could* check
          *     for bogus scope ids first.
          */
         *addr = apr_pstrmemdup(p, str, addrlen);
@@ -335,13 +335,13 @@ APR_DECLARE(apr_status_t) apr_parse_addr
 
 static apr_status_t call_resolver(apr_sockaddr_t **sa,
                                   const char *hostname, apr_int32_t family,
-                                  apr_port_t port, apr_int32_t flags, 
+                                  apr_port_t port, apr_int32_t flags,
                                   apr_pool_t *p)
 {
     struct addrinfo hints, *ai, *ai_list;
     apr_sockaddr_t *prev_sa;
     int error;
-    char *servname = NULL; 
+    char *servname = NULL;
 
     memset(&hints, 0, sizeof(hints));
     hints.ai_family = family;
@@ -356,16 +356,16 @@ static apr_status_t call_resolver(apr_so
 #endif
 
 #ifdef __MVS__
-    /* z/OS will not return IPv4 address under AF_UNSPEC if any IPv6 results 
-     * are returned, w/o AI_ALL. 
+    /* z/OS will not return IPv4 address under AF_UNSPEC if any IPv6 results
+     * are returned, w/o AI_ALL.
      */
-    if (family == APR_UNSPEC) { 
+    if (family == APR_UNSPEC) {
        hints.ai_flags |= AI_ALL;
     }
 #endif
 
     if(hostname == NULL) {
-#ifdef AI_PASSIVE 
+#ifdef AI_PASSIVE
         /* If hostname is NULL, assume we are trying to bind to all
          * interfaces. */
         hints.ai_flags |= AI_PASSIVE;
@@ -426,11 +426,11 @@ static apr_status_t call_resolver(apr_so
         if (error == EAI_SYSTEM) {
             return errno ? errno : APR_EGENERAL;
         }
-        else 
+        else
         {
             /* issues with representing this with APR's error scheme:
-             * glibc uses negative values for these numbers, perhaps so 
-             * they don't conflict with h_errno values...  Tru64 uses 
+             * glibc uses negative values for these numbers, perhaps so
+             * they don't conflict with h_errno values...  Tru64 uses
              * positive values which conflict with h_errno values
              */
 #if defined(NEGATIVE_EAI)
@@ -491,9 +491,9 @@ static apr_status_t call_resolver(apr_so
     return APR_SUCCESS;
 }
 
-static apr_status_t find_addresses(apr_sockaddr_t **sa, 
+static apr_status_t find_addresses(apr_sockaddr_t **sa,
                                    const char *hostname, apr_int32_t family,
-                                   apr_port_t port, apr_int32_t flags, 
+                                   apr_port_t port, apr_int32_t flags,
                                    apr_pool_t *p)
 {
     if (flags & APR_IPV4_ADDR_OK) {
@@ -525,9 +525,9 @@ static apr_status_t find_addresses(apr_s
 
 #else /* end of HAVE_GETADDRINFO code */
 
-static apr_status_t find_addresses(apr_sockaddr_t **sa, 
+static apr_status_t find_addresses(apr_sockaddr_t **sa,
                                    const char *hostname, apr_int32_t family,
-                                   apr_port_t port, apr_int32_t flags, 
+                                   apr_port_t port, apr_int32_t flags,
                                    apr_pool_t *p)
 {
     struct hostent *hp;
@@ -573,7 +573,7 @@ static apr_status_t find_addresses(apr_s
 #else
 #if defined(GETHOSTBYNAME_R_GLIBC2)
         /* Linux glibc2+ */
-        gethostbyname_r(hostname, &hs, tmp, GETHOSTBYNAME_BUFLEN - 1, 
+        gethostbyname_r(hostname, &hs, tmp, GETHOSTBYNAME_BUFLEN - 1,
                         &hp, &hosterror);
 #else
         /* Solaris, Irix et alia */
@@ -632,7 +632,7 @@ static apr_status_t find_addresses(apr_s
 #endif /* end of !HAVE_GETADDRINFO code */
 
 APR_DECLARE(apr_status_t) apr_sockaddr_info_get(apr_sockaddr_t **sa,
-                                                const char *hostname, 
+                                                const char *hostname,
                                                 apr_int32_t family, apr_port_t port,
                                                 apr_int32_t flags, apr_pool_t *p)
 {
@@ -791,7 +791,7 @@ APR_DECLARE(apr_status_t) apr_getnameinf
                 return errno + APR_OS_START_SYSERR;
             }
         }
-        else 
+        else
 #endif
         {
 #if defined(NEGATIVE_EAI)
@@ -800,7 +800,7 @@ APR_DECLARE(apr_status_t) apr_getnameinf
             return rc + APR_OS_START_EAIERR; /* return the EAI_ error */
         }
     }
-    *hostname = sockaddr->hostname = apr_pstrdup(sockaddr->pool, 
+    *hostname = sockaddr->hostname = apr_pstrdup(sockaddr->pool,
                                                  tmphostname);
     return APR_SUCCESS;
 #else
@@ -816,18 +816,18 @@ APR_DECLARE(apr_status_t) apr_getnameinf
 
 #if defined(GETHOSTBYNAME_R_HOSTENT_DATA)
     /* AIX, HP/UX, D/UX et alia */
-    gethostbyaddr_r((char *)&sockaddr->sa.sin.sin_addr, 
+    gethostbyaddr_r((char *)&sockaddr->sa.sin.sin_addr,
                   sizeof(struct in_addr), AF_INET, &hs, &hd);
     hptr = &hs;
 #else
 #if defined(GETHOSTBYNAME_R_GLIBC2)
     /* Linux glibc2+ */
-    gethostbyaddr_r((char *)&sockaddr->sa.sin.sin_addr, 
+    gethostbyaddr_r((char *)&sockaddr->sa.sin.sin_addr,
                     sizeof(struct in_addr), AF_INET,
                     &hs, tmp, GETHOSTBYNAME_BUFLEN - 1, &hptr, &hosterror);
 #else
     /* Solaris, Irix et alia */
-    hptr = gethostbyaddr_r((char *)&sockaddr->sa.sin.sin_addr, 
+    hptr = gethostbyaddr_r((char *)&sockaddr->sa.sin.sin_addr,
                            sizeof(struct in_addr), AF_INET,
                            &hs, tmp, GETHOSTBYNAME_BUFLEN, &hosterror);
 #endif /* !defined(GETHOSTBYNAME_R_GLIBC2) */
@@ -838,7 +838,7 @@ APR_DECLARE(apr_status_t) apr_getnameinf
 #endif /* !defined(GETHOSTBYNAME_R_HOSTENT_DATA) */
 #else
     struct hostent *hptr;
-    hptr = gethostbyaddr((char *)&sockaddr->sa.sin.sin_addr, 
+    hptr = gethostbyaddr((char *)&sockaddr->sa.sin.sin_addr,
                          sizeof(struct in_addr), AF_INET);
 #endif
 
@@ -1046,7 +1046,7 @@ static apr_status_t parse_ip(apr_ipsubne
     /* supported flavors of IP:
      *
      * . IPv6 numeric address string (e.g., "fe80::1")
-     * 
+     *
      *   IMPORTANT: Don't store IPv4-mapped IPv6 address as an IPv6 address.
      *
      * . IPv4 numeric address string (e.g., "127.0.0.1")
@@ -1093,7 +1093,7 @@ static int looks_like_ip(const char *ips
     if (strlen(ipstr) == 0) {
         return 0;
     }
-    
+
     if (strchr(ipstr, ':')) {
         /* definitely not a hostname; assume it is intended to be an IPv6 address */
         return 1;
@@ -1118,14 +1118,14 @@ static void fix_subnet(apr_ipsubnet_t *i
 }
 
 /* be sure not to store any IPv4 address as a v4-mapped IPv6 address */
-APR_DECLARE(apr_status_t) apr_ipsubnet_create(apr_ipsubnet_t **ipsub, const char *ipstr, 
+APR_DECLARE(apr_status_t) apr_ipsubnet_create(apr_ipsubnet_t **ipsub, const char *ipstr,
                                               const char *mask_or_numbits, apr_pool_t *p)
 {
     apr_status_t rv;
     char *endptr;
     long bits, maxbits = 32;
 
-    /* filter out stuff which doesn't look remotely like an IP address; this helps 
+    /* filter out stuff which doesn't look remotely like an IP address; this helps
      * callers like mod_access which have a syntax allowing hostname or IP address;
      * APR_EINVAL tells the caller that it was probably not intended to be an IP
      * address
@@ -1227,7 +1227,7 @@ APR_DECLARE(apr_status_t) apr_sockaddr_z
     return APR_ENOTIMPL;
 #else
     unsigned int idx;
-    
+
     if (sa->family != APR_INET6
         || !IN6_IS_ADDR_LINKLOCAL((struct in6_addr *)sa->ipaddr_ptr)) {
         return APR_EBADIP;
@@ -1266,7 +1266,7 @@ APR_DECLARE(apr_status_t) apr_sockaddr_z
 #else
     if (sa->family != APR_INET6 || !sa->sa.sin6.sin6_scope_id) {
         return APR_EBADIP;
-    }        
+    }
 
     if (name) {
         char *buf = apr_palloc(p, IF_NAMESIZE);
@@ -1276,7 +1276,7 @@ APR_DECLARE(apr_status_t) apr_sockaddr_z
     }
 
     if (id) *id = sa->sa.sin6.sin6_scope_id;
-    
+
     return APR_SUCCESS;
 #endif
 }

Modified: apr/apr/trunk/network_io/unix/sockets.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/network_io/unix/sockets.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/network_io/unix/sockets.c (original)
+++ apr/apr/trunk/network_io/unix/sockets.c Sun Nov 20 07:14:38 2022
@@ -50,7 +50,7 @@ static apr_status_t socket_cleanup(void
         /* XXX: Check for return values ? */
         unlink(thesocket->local_addr->hostname);
     }
-#endif        
+#endif
     if (close(sd) == 0) {
         return APR_SUCCESS;
     }
@@ -200,9 +200,9 @@ apr_status_t apr_socket_create(apr_socke
                               socket_child_cleanup);
 
     return APR_SUCCESS;
-} 
+}
 
-apr_status_t apr_socket_shutdown(apr_socket_t *thesocket, 
+apr_status_t apr_socket_shutdown(apr_socket_t *thesocket,
                                  apr_shutdown_how_e how)
 {
     return (shutdown(thesocket->socketdes, how) == -1) ? errno : APR_SUCCESS;
@@ -215,7 +215,7 @@ apr_status_t apr_socket_close(apr_socket
 
 apr_status_t apr_socket_bind(apr_socket_t *sock, apr_sockaddr_t *sa)
 {
-    if (bind(sock->socketdes, 
+    if (bind(sock->socketdes,
              (struct sockaddr *)&sa->sa, sa->salen) == -1) {
         return errno;
     }
@@ -275,7 +275,7 @@ apr_status_t apr_socket_accept(apr_socke
         return errno;
     }
 #ifdef TPF
-    if (s == 0) { 
+    if (s == 0) {
         /* 0 is an invalid socket for TPF */
         return APR_EINTR;
     }
@@ -304,8 +304,8 @@ apr_status_t apr_socket_accept(apr_socke
 
     *(*new)->local_addr = *sock->local_addr;
 
-    /* The above assignment just overwrote the pool entry. Setting the local_addr 
-       pool for the accepted socket back to what it should be.  Otherwise all 
+    /* The above assignment just overwrote the pool entry. Setting the local_addr
+       pool for the accepted socket back to what it should be.  Otherwise all
        allocations for this socket will come from a server pool that is not
        freed until the process goes down.*/
     (*new)->local_addr->pool = connection_context;
@@ -348,7 +348,7 @@ apr_status_t apr_socket_accept(apr_socke
         !memcmp(sock->local_addr->ipaddr_ptr,
                 generic_inaddr_any,
                 sock->local_addr->ipaddr_len)) {
-        /* If the interface address inside the listening socket's local_addr wasn't 
+        /* If the interface address inside the listening socket's local_addr wasn't
          * up-to-date, we don't know local interface of the connected socket either.
          *
          * If the listening socket was not bound to a specific interface, we
@@ -387,7 +387,7 @@ apr_status_t apr_socket_accept(apr_socke
 
 apr_status_t apr_socket_connect(apr_socket_t *sock, apr_sockaddr_t *sa)
 {
-    int rc;        
+    int rc;
 
     do {
         rc = connect(sock->socketdes,
@@ -409,7 +409,7 @@ apr_status_t apr_socket_connect(apr_sock
         {
             int error;
             apr_socklen_t len = sizeof(error);
-            if ((rc = getsockopt(sock->socketdes, SOL_SOCKET, SO_ERROR, 
+            if ((rc = getsockopt(sock->socketdes, SOL_SOCKET, SO_ERROR,
                                  (char *)&error, &len)) < 0) {
                 return errno;
             }
@@ -509,8 +509,8 @@ apr_status_t apr_os_sock_get(apr_os_sock
     return APR_SUCCESS;
 }
 
-apr_status_t apr_os_sock_make(apr_socket_t **apr_sock, 
-                              apr_os_sock_info_t *os_sock_info, 
+apr_status_t apr_os_sock_make(apr_socket_t **apr_sock,
+                              apr_os_sock_info_t *os_sock_info,
                               apr_pool_t *cont)
 {
     alloc_socket(apr_sock, cont);
@@ -518,8 +518,8 @@ apr_status_t apr_os_sock_make(apr_socket
     (*apr_sock)->timeout = -1;
     (*apr_sock)->socketdes = *os_sock_info->os_sock;
     if (os_sock_info->local) {
-        memcpy(&(*apr_sock)->local_addr->sa.sin, 
-               os_sock_info->local, 
+        memcpy(&(*apr_sock)->local_addr->sa.sin,
+               os_sock_info->local,
                (*apr_sock)->local_addr->salen);
         /* XXX IPv6 - this assumes sin_port and sin6_port at same offset */
         (*apr_sock)->local_addr->port = ntohs((*apr_sock)->local_addr->sa.sin.sin_port);
@@ -531,7 +531,7 @@ apr_status_t apr_os_sock_make(apr_socket
 #ifndef HAVE_POLL
         (*apr_sock)->connected = 1;
 #endif
-        memcpy(&(*apr_sock)->remote_addr->sa.sin, 
+        memcpy(&(*apr_sock)->remote_addr->sa.sin,
                os_sock_info->remote,
                (*apr_sock)->remote_addr->salen);
         /* XXX IPv6 - this assumes sin_port and sin6_port at same offset */
@@ -540,14 +540,14 @@ apr_status_t apr_os_sock_make(apr_socket
     else {
         (*apr_sock)->remote_addr_unknown = 1;
     }
-        
+
     (*apr_sock)->inherit = 0;
-    apr_pool_cleanup_register((*apr_sock)->pool, (void *)(*apr_sock), 
+    apr_pool_cleanup_register((*apr_sock)->pool, (void *)(*apr_sock),
                               socket_cleanup, socket_cleanup);
     return APR_SUCCESS;
 }
 
-apr_status_t apr_os_sock_put(apr_socket_t **sock, apr_os_sock_t *thesock, 
+apr_status_t apr_os_sock_put(apr_socket_t **sock, apr_os_sock_t *thesock,
                            apr_pool_t *cont)
 {
     /* XXX Bogus assumption that *sock points at anything legit */

Modified: apr/apr/trunk/network_io/unix/sockopt.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/network_io/unix/sockopt.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/network_io/unix/sockopt.c (original)
+++ apr/apr/trunk/network_io/unix/sockopt.c Sun Nov 20 07:14:38 2022
@@ -90,14 +90,14 @@ apr_status_t apr_socket_timeout_set(apr_
             }
             apr_set_option(sock, APR_SO_NONBLOCK, 1);
         }
-    } 
+    }
     else if (t < 0 && sock->timeout >= 0) {
-        if (apr_is_option_set(sock, APR_SO_NONBLOCK) != 0) { 
-            if ((stat = soblock(sock->socketdes)) != APR_SUCCESS) { 
-                return stat; 
+        if (apr_is_option_set(sock, APR_SO_NONBLOCK) != 0) {
+            if ((stat = soblock(sock->socketdes)) != APR_SUCCESS) {
+                return stat;
             }
             apr_set_option(sock, APR_SO_NONBLOCK, 0);
-        } 
+        }
     }
     /* must disable the incomplete read support if we disable
      * a timeout
@@ -110,7 +110,7 @@ apr_status_t apr_socket_timeout_set(apr_
 }
 
 
-apr_status_t apr_socket_opt_set(apr_socket_t *sock, 
+apr_status_t apr_socket_opt_set(apr_socket_t *sock,
                                 apr_int32_t opt, apr_int32_t on)
 {
     int one;
@@ -182,7 +182,7 @@ apr_status_t apr_socket_opt_set(apr_sock
     case APR_SO_NONBLOCK:
         if (apr_is_option_set(sock, APR_SO_NONBLOCK) != on) {
             if (on) {
-                if ((rv = sononblock(sock->socketdes)) != APR_SUCCESS) 
+                if ((rv = sononblock(sock->socketdes)) != APR_SUCCESS)
                     return rv;
             }
             else {
@@ -213,7 +213,7 @@ apr_status_t apr_socket_opt_set(apr_sock
             int optlevel = IPPROTO_TCP;
             int optname = TCP_DEFER_ACCEPT;
 
-            if (setsockopt(sock->socketdes, optlevel, optname, 
+            if (setsockopt(sock->socketdes, optlevel, optname,
                            (void *)&on, sizeof(int)) == -1) {
                 return errno;
             }
@@ -348,8 +348,8 @@ apr_status_t apr_socket_opt_set(apr_sock
         return APR_EINVAL;
     }
 
-    return APR_SUCCESS; 
-}         
+    return APR_SUCCESS;
+}
 
 
 apr_status_t apr_socket_timeout_get(apr_socket_t *sock, apr_interval_time_t *t)
@@ -359,7 +359,7 @@ apr_status_t apr_socket_timeout_get(apr_
 }
 
 
-apr_status_t apr_socket_opt_get(apr_socket_t *sock, 
+apr_status_t apr_socket_opt_get(apr_socket_t *sock,
                                 apr_int32_t opt, apr_int32_t *on)
 {
     switch(opt) {
@@ -392,7 +392,7 @@ apr_status_t apr_gethostname(char *buf,
     if (gethostname(buf, len) == 0) {
 #else
     if (gethostname(buf, len) != 0) {
-#endif  
+#endif
         buf[0] = '\0';
         return errno;
     }

Modified: apr/apr/trunk/network_io/win32/sendrecv.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/network_io/win32/sendrecv.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/network_io/win32/sendrecv.c (original)
+++ apr/apr/trunk/network_io/win32/sendrecv.c Sun Nov 20 07:14:38 2022
@@ -25,10 +25,10 @@
 #endif
 
 /* MAX_SEGMENT_SIZE is the maximum amount of data that will be sent to a client
- * in one call of TransmitFile. This number must be small enough to give the 
+ * in one call of TransmitFile. This number must be small enough to give the
  * slowest client time to receive the data before the socket timeout triggers.
  * The same problem can exist with apr_socket_send(). In that case, we rely on
- * the application to adjust socket timeouts and max send segment 
+ * the application to adjust socket timeouts and max send segment
  * sizes appropriately.
  * For example, Apache will in most cases call apr_socket_send() with less
  * than 8193 bytes.
@@ -61,7 +61,7 @@ APR_DECLARE(apr_status_t) apr_socket_sen
 
 
 APR_DECLARE(apr_status_t) apr_socket_recv(apr_socket_t *sock, char *buf,
-                                          apr_size_t *len) 
+                                          apr_size_t *len)
 {
     apr_ssize_t rv;
     WSABUF wsaData;
@@ -129,13 +129,13 @@ APR_DECLARE(apr_status_t) apr_socket_sen
 
 APR_DECLARE(apr_status_t) apr_socket_sendto(apr_socket_t *sock,
                                             apr_sockaddr_t *where,
-                                            apr_int32_t flags, const char *buf, 
+                                            apr_int32_t flags, const char *buf,
                                             apr_size_t *len)
 {
     apr_ssize_t rv;
 
-    rv = sendto(sock->socketdes, buf, (int)*len, flags, 
-                (const struct sockaddr*)&where->sa, 
+    rv = sendto(sock->socketdes, buf, (int)*len, flags,
+                (const struct sockaddr*)&where->sa,
                 where->salen);
     if (rv == SOCKET_ERROR) {
         *len = 0;
@@ -147,23 +147,23 @@ APR_DECLARE(apr_status_t) apr_socket_sen
 }
 
 
-APR_DECLARE(apr_status_t) apr_socket_recvfrom(apr_sockaddr_t *from, 
+APR_DECLARE(apr_status_t) apr_socket_recvfrom(apr_sockaddr_t *from,
                                               apr_socket_t *sock,
-                                              apr_int32_t flags, 
+                                              apr_int32_t flags,
                                               char *buf, apr_size_t *len)
 {
     apr_ssize_t rv;
 
     from->salen = sizeof(from->sa);
 
-    rv = recvfrom(sock->socketdes, buf, (int)*len, flags, 
+    rv = recvfrom(sock->socketdes, buf, (int)*len, flags,
                   (struct sockaddr*)&from->sa, &from->salen);
     if (rv == SOCKET_ERROR) {
         (*len) = 0;
         return apr_get_netos_error();
     }
 
-    apr_sockaddr_vars_set(from, from->sa.sin.sin_family, 
+    apr_sockaddr_vars_set(from, from->sa.sin.sin_family,
                           ntohs(from->sa.sin.sin_port));
 
     (*len) = rv;
@@ -175,8 +175,8 @@ APR_DECLARE(apr_status_t) apr_socket_rec
 
 
 #if APR_HAS_SENDFILE
-static apr_status_t collapse_iovec(char **off, apr_size_t *len, 
-                                   struct iovec *iovec, int numvec, 
+static apr_status_t collapse_iovec(char **off, apr_size_t *len,
+                                   struct iovec *iovec, int numvec,
                                    char *buf, apr_size_t buflen)
 {
     if (numvec == 1) {
@@ -206,9 +206,9 @@ static apr_status_t collapse_iovec(char
 
 
 /*
- * apr_status_t apr_socket_sendfile(apr_socket_t *, apr_file_t *, apr_hdtr_t *, 
+ * apr_status_t apr_socket_sendfile(apr_socket_t *, apr_file_t *, apr_hdtr_t *,
  *                                 apr_off_t *, apr_size_t *, apr_int32_t flags)
- *    Send a file from an open file descriptor to a socket, along with 
+ *    Send a file from an open file descriptor to a socket, along with
  *    optional headers and trailers
  * arg 1) The socket to which we're writing
  * arg 2) The open file from which to read
@@ -217,12 +217,12 @@ static apr_status_t collapse_iovec(char
  * arg 5) Number of bytes to send out of the file
  * arg 6) APR flags that are mapped to OS specific flags
  */
-APR_DECLARE(apr_status_t) apr_socket_sendfile(apr_socket_t *sock, 
+APR_DECLARE(apr_status_t) apr_socket_sendfile(apr_socket_t *sock,
                                               apr_file_t *file,
                                               apr_hdtr_t *hdtr,
                                               apr_off_t *offset,
                                               apr_size_t *len,
-                                              apr_int32_t flags) 
+                                              apr_int32_t flags)
 {
     apr_status_t status = APR_SUCCESS;
     apr_status_t rv;
@@ -263,7 +263,7 @@ APR_DECLARE(apr_status_t) apr_socket_sen
      * Long TransmitFile requests are defined as requests that require more
      * than a single read from the file or a cache; the request therefore
      * depends on the size of the file and the specified length of the send
-     * packet. 
+     * packet.
      *
      * Use of TF_USE_KERNEL_APC can deliver significant performance benefits.
      * It is possible (though unlikely), however, that the thread in which
@@ -281,7 +281,7 @@ APR_DECLARE(apr_status_t) apr_socket_sen
     /* Handle the goofy case of sending headers/trailers and a zero byte file */
     if (!bytes_to_send && hdtr) {
         if (hdtr->numheaders) {
-            rv = apr_socket_sendv(sock, hdtr->headers, hdtr->numheaders, 
+            rv = apr_socket_sendv(sock, hdtr->headers, hdtr->numheaders,
                                   &nbytes);
             if (rv != APR_SUCCESS)
                 return rv;
@@ -304,8 +304,8 @@ APR_DECLARE(apr_status_t) apr_socket_sen
         apr_size_t head_length = tfb.HeadLength;
         ptfb = &tfb;
         nbytes = 0;
-        rv = collapse_iovec((char **)&ptfb->Head, &head_length, 
-                            hdtr->headers, hdtr->numheaders, 
+        rv = collapse_iovec((char **)&ptfb->Head, &head_length,
+                            hdtr->headers, hdtr->numheaders,
                             hdtrbuf, sizeof(hdtrbuf));
 
         tfb.HeadLength = (DWORD)head_length;
@@ -356,7 +356,7 @@ APR_DECLARE(apr_status_t) apr_socket_sen
         sock->overlapped->Offset = (DWORD)(curoff);
 #if APR_HAS_LARGE_FILES
         sock->overlapped->OffsetHigh = (DWORD)(curoff >> 32);
-#endif  
+#endif
         /* XXX BoundsChecker claims dwFlags must not be zero. */
         rv = pfn_transmit_file(sock->socketdes,  /* socket */
                                file->filehand, /* open file descriptor of the file to be sent */
@@ -368,10 +368,10 @@ APR_DECLARE(apr_status_t) apr_socket_sen
         if (!rv) {
             status = apr_get_netos_error();
             if ((status == APR_FROM_OS_ERROR(ERROR_IO_PENDING)) ||
-                (status == APR_FROM_OS_ERROR(WSA_IO_PENDING))) 
+                (status == APR_FROM_OS_ERROR(WSA_IO_PENDING)))
             {
-                rv = WaitForSingleObject(sock->overlapped->hEvent, 
-                                         (DWORD)(sock->timeout >= 0 
+                rv = WaitForSingleObject(sock->overlapped->hEvent,
+                                         (DWORD)(sock->timeout >= 0
                                                  ? sock->timeout_ms : INFINITE));
                 if (rv == WAIT_OBJECT_0) {
                     status = APR_SUCCESS;

Modified: apr/apr/trunk/network_io/win32/sockets.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/network_io/win32/sockets.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/network_io/win32/sockets.c (original)
+++ apr/apr/trunk/network_io/win32/sockets.c Sun Nov 20 07:14:38 2022
@@ -64,7 +64,7 @@ static void set_socket_vars(apr_socket_t
         apr_set_option(sock, APR_IPV6_V6ONLY, 1);
     }
 #endif
-}                                                                                                  
+}
 static void alloc_socket(apr_socket_t **new, apr_pool_t *p)
 {
     *new = (apr_socket_t *)apr_pcalloc(p, sizeof(apr_socket_t));
@@ -72,7 +72,7 @@ static void alloc_socket(apr_socket_t **
     (*new)->local_addr = (apr_sockaddr_t *)apr_pcalloc((*new)->pool,
                                                        sizeof(apr_sockaddr_t));
     (*new)->local_addr->pool = p;
-    
+
     (*new)->remote_addr = (apr_sockaddr_t *)apr_pcalloc((*new)->pool,
                                                         sizeof(apr_sockaddr_t));
     (*new)->remote_addr->pool = p;
@@ -91,7 +91,7 @@ APR_DECLARE(apr_status_t) apr_socket_pro
 }
 
 APR_DECLARE(apr_status_t) apr_socket_create(apr_socket_t **new, int family,
-                                            int type, int protocol, 
+                                            int type, int protocol,
                                             apr_pool_t *cont)
 {
     DWORD flags;
@@ -153,11 +153,11 @@ APR_DECLARE(apr_status_t) apr_socket_cre
     (*new)->timeout = -1;
     (*new)->disconnected = 0;
 
-    apr_pool_cleanup_register((*new)->pool, (void *)(*new), 
+    apr_pool_cleanup_register((*new)->pool, (void *)(*new),
                         socket_cleanup, apr_pool_cleanup_null);
 
     return APR_SUCCESS;
-} 
+}
 
 APR_DECLARE(apr_status_t) apr_socket_shutdown(apr_socket_t *thesocket,
                                               apr_shutdown_how_e how)
@@ -199,8 +199,8 @@ APR_DECLARE(apr_status_t) apr_socket_clo
 APR_DECLARE(apr_status_t) apr_socket_bind(apr_socket_t *sock,
                                           apr_sockaddr_t *sa)
 {
-    if (bind(sock->socketdes, 
-             (struct sockaddr *)&sa->sa, 
+    if (bind(sock->socketdes,
+             (struct sockaddr *)&sa->sa,
              sa->salen) == -1) {
         return apr_get_netos_error();
     }
@@ -236,7 +236,7 @@ APR_DECLARE(apr_status_t) apr_socket_lis
         return APR_SUCCESS;
 }
 
-APR_DECLARE(apr_status_t) apr_socket_accept(apr_socket_t **new, 
+APR_DECLARE(apr_status_t) apr_socket_accept(apr_socket_t **new,
                                             apr_socket_t *sock, apr_pool_t *p)
 {
     SOCKET s;
@@ -255,10 +255,10 @@ APR_DECLARE(apr_status_t) apr_socket_acc
     }
 
     alloc_socket(new, p);
-    set_socket_vars(*new, sock->local_addr->sa.sin.sin_family, SOCK_STREAM, 
+    set_socket_vars(*new, sock->local_addr->sa.sin.sin_family, SOCK_STREAM,
                     sock->protocol);
 
-    (*new)->timeout = -1;   
+    (*new)->timeout = -1;
     (*new)->disconnected = 0;
 
     (*new)->socketdes = s;
@@ -269,8 +269,8 @@ APR_DECLARE(apr_status_t) apr_socket_acc
 
     *(*new)->local_addr = *sock->local_addr;
 
-    /* The above assignment just overwrote the pool entry. Setting the local_addr 
-       pool for the accepted socket back to what it should be.  Otherwise all 
+    /* The above assignment just overwrote the pool entry. Setting the local_addr
+       pool for the accepted socket back to what it should be.  Otherwise all
        allocations for this socket will come from a server pool that is not
        freed until the process goes down.*/
     (*new)->local_addr->pool = p;
@@ -314,7 +314,7 @@ APR_DECLARE(apr_status_t) apr_socket_acc
         (*new)->local_interface_unknown = 1;
     }
 
-    apr_pool_cleanup_register((*new)->pool, (void *)(*new), 
+    apr_pool_cleanup_register((*new)->pool, (void *)(*new),
                         socket_cleanup, apr_pool_cleanup_null);
     return APR_SUCCESS;
 }
@@ -360,7 +360,7 @@ static apr_status_t wait_for_connect(apr
     return APR_SUCCESS;
 }
 
-APR_DECLARE(apr_status_t) apr_socket_connect(apr_socket_t *sock, 
+APR_DECLARE(apr_status_t) apr_socket_connect(apr_socket_t *sock,
                                              apr_sockaddr_t *sa)
 {
     apr_status_t rv;
@@ -380,8 +380,8 @@ APR_DECLARE(apr_status_t) apr_socket_con
     if (rv == APR_FROM_OS_ERROR(WSAEWOULDBLOCK)) {
         if (sock->timeout == 0) {
             /* Tell the app that the connect is in progress...
-             * Gotta play some games here.  connect on Unix will return 
-             * EINPROGRESS under the same circumstances that Windows 
+             * Gotta play some games here.  connect on Unix will return
+             * EINPROGRESS under the same circumstances that Windows
              * returns WSAEWOULDBLOCK. Do some adhoc canonicalization...
              */
             rv = APR_FROM_OS_ERROR(WSAEINPROGRESS);
@@ -483,8 +483,8 @@ APR_DECLARE(apr_status_t) apr_os_sock_ma
     (*apr_sock)->disconnected = 0;
     (*apr_sock)->socketdes = *os_sock_info->os_sock;
     if (os_sock_info->local) {
-        memcpy(&(*apr_sock)->local_addr->sa.sin, 
-               os_sock_info->local, 
+        memcpy(&(*apr_sock)->local_addr->sa.sin,
+               os_sock_info->local,
                (*apr_sock)->local_addr->salen);
         (*apr_sock)->local_addr->pool = cont;
         /* XXX IPv6 - this assumes sin_port and sin6_port at same offset */
@@ -494,7 +494,7 @@ APR_DECLARE(apr_status_t) apr_os_sock_ma
         (*apr_sock)->local_port_unknown = (*apr_sock)->local_interface_unknown = 1;
     }
     if (os_sock_info->remote) {
-        memcpy(&(*apr_sock)->remote_addr->sa.sin, 
+        memcpy(&(*apr_sock)->remote_addr->sa.sin,
                os_sock_info->remote,
                (*apr_sock)->remote_addr->salen);
         (*apr_sock)->remote_addr->pool = cont;
@@ -502,8 +502,8 @@ APR_DECLARE(apr_status_t) apr_os_sock_ma
         (*apr_sock)->remote_addr->port = ntohs((*apr_sock)->remote_addr->sa.sin.sin_port);
         (*apr_sock)->remote_addr_unknown = 0;
     }
-        
-    apr_pool_cleanup_register((*apr_sock)->pool, (void *)(*apr_sock), 
+
+    apr_pool_cleanup_register((*apr_sock)->pool, (void *)(*apr_sock),
                         socket_cleanup, apr_pool_cleanup_null);
 
     return APR_SUCCESS;
@@ -533,14 +533,14 @@ APR_DECLARE(apr_status_t) apr_os_sock_pu
  * This is not trivial to implement.
  */
 
-APR_DECLARE(apr_status_t) apr_socket_inherit_set(apr_socket_t *socket)    
-{    
+APR_DECLARE(apr_status_t) apr_socket_inherit_set(apr_socket_t *socket)
+{
     return APR_ENOTIMPL;
-}    
+}
 
-APR_DECLARE(apr_status_t) apr_socket_inherit_unset(apr_socket_t *socket)    
-{    
+APR_DECLARE(apr_status_t) apr_socket_inherit_unset(apr_socket_t *socket)
+{
     return APR_ENOTIMPL;
-}    
+}
 
 APR_POOL_IMPLEMENT_ACCESSOR(socket);

Modified: apr/apr/trunk/network_io/win32/sockopt.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/network_io/win32/sockopt.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/network_io/win32/sockopt.c (original)
+++ apr/apr/trunk/network_io/win32/sockopt.c Sun Nov 20 07:14:38 2022
@@ -69,15 +69,15 @@ APR_DECLARE(apr_status_t) apr_socket_tim
             apr_set_option(sock, APR_SO_NONBLOCK, 0);
         }
         /* Reset socket timeouts if the new timeout differs from the old timeout */
-        if (sock->timeout != t) 
+        if (sock->timeout != t)
         {
             /* Win32 timeouts are in msec, represented as int */
             sock->timeout_ms = (int)apr_time_as_msec(t);
-            setsockopt(sock->socketdes, SOL_SOCKET, SO_RCVTIMEO, 
-                       (char *) &sock->timeout_ms, 
+            setsockopt(sock->socketdes, SOL_SOCKET, SO_RCVTIMEO,
+                       (char *) &sock->timeout_ms,
                        sizeof(sock->timeout_ms));
-            setsockopt(sock->socketdes, SOL_SOCKET, SO_SNDTIMEO, 
-                       (char *) &sock->timeout_ms, 
+            setsockopt(sock->socketdes, SOL_SOCKET, SO_SNDTIMEO,
+                       (char *) &sock->timeout_ms,
                        sizeof(sock->timeout_ms));
         }
     }
@@ -86,9 +86,9 @@ APR_DECLARE(apr_status_t) apr_socket_tim
         /* Set the socket to blocking with infinite timeouts */
         if ((stat = soblock(sock->socketdes)) != APR_SUCCESS)
             return stat;
-        setsockopt(sock->socketdes, SOL_SOCKET, SO_RCVTIMEO, 
+        setsockopt(sock->socketdes, SOL_SOCKET, SO_RCVTIMEO,
                    (char *) &zero, sizeof(zero));
-        setsockopt(sock->socketdes, SOL_SOCKET, SO_SNDTIMEO, 
+        setsockopt(sock->socketdes, SOL_SOCKET, SO_SNDTIMEO,
                    (char *) &zero, sizeof(zero));
     }
     sock->timeout = t;
@@ -107,7 +107,7 @@ APR_DECLARE(apr_status_t) apr_socket_opt
     switch (opt) {
     case APR_SO_KEEPALIVE:
         if (on != apr_is_option_set(sock, APR_SO_KEEPALIVE)) {
-            if (setsockopt(sock->socketdes, SOL_SOCKET, SO_KEEPALIVE, 
+            if (setsockopt(sock->socketdes, SOL_SOCKET, SO_KEEPALIVE,
                            (void *)&one, sizeof(int)) == -1) {
                 return apr_get_netos_error();
             }
@@ -116,7 +116,7 @@ APR_DECLARE(apr_status_t) apr_socket_opt
         break;
     case APR_SO_DEBUG:
         if (on != apr_is_option_set(sock, APR_SO_DEBUG)) {
-            if (setsockopt(sock->socketdes, SOL_SOCKET, SO_DEBUG, 
+            if (setsockopt(sock->socketdes, SOL_SOCKET, SO_DEBUG,
                            (void *)&one, sizeof(int)) == -1) {
                 return apr_get_netos_error();
             }
@@ -137,7 +137,7 @@ APR_DECLARE(apr_status_t) apr_socket_opt
         break;
     case APR_SO_BROADCAST:
         if (on != apr_is_option_set(sock, APR_SO_BROADCAST)) {
-           if (setsockopt(sock->socketdes, SOL_SOCKET, SO_BROADCAST, 
+           if (setsockopt(sock->socketdes, SOL_SOCKET, SO_BROADCAST,
                            (void *)&one, sizeof(int)) == -1) {
                 return apr_get_netos_error();
             }
@@ -146,7 +146,7 @@ APR_DECLARE(apr_status_t) apr_socket_opt
         break;
     case APR_SO_REUSEADDR:
         if (on != apr_is_option_set(sock, APR_SO_REUSEADDR)) {
-            if (setsockopt(sock->socketdes, SOL_SOCKET, SO_REUSEADDR, 
+            if (setsockopt(sock->socketdes, SOL_SOCKET, SO_REUSEADDR,
                            (void *)&one, sizeof(int)) == -1) {
                 return apr_get_netos_error();
             }
@@ -156,7 +156,7 @@ APR_DECLARE(apr_status_t) apr_socket_opt
     case APR_SO_NONBLOCK:
         if (apr_is_option_set(sock, APR_SO_NONBLOCK) != on) {
             if (on) {
-                if ((stat = sononblock(sock->socketdes)) != APR_SUCCESS) 
+                if ((stat = sononblock(sock->socketdes)) != APR_SUCCESS)
                     return stat;
             }
             else {
@@ -172,7 +172,7 @@ APR_DECLARE(apr_status_t) apr_socket_opt
             struct linger li;
             li.l_onoff = on;
             li.l_linger = APR_MAX_SECS_TO_LINGER;
-            if (setsockopt(sock->socketdes, SOL_SOCKET, SO_LINGER, 
+            if (setsockopt(sock->socketdes, SOL_SOCKET, SO_LINGER,
                            (char *) &li, sizeof(struct linger)) == -1) {
                 return apr_get_netos_error();
             }
@@ -186,7 +186,7 @@ APR_DECLARE(apr_status_t) apr_socket_opt
             int optlevel = IPPROTO_TCP;
             int optname = TCP_DEFER_ACCEPT;
 
-            if (setsockopt(sock->socketdes, optlevel, optname, 
+            if (setsockopt(sock->socketdes, optlevel, optname,
                            (void *)&on, sizeof(int)) == -1) {
                 return apr_get_netos_error();
             }
@@ -215,7 +215,7 @@ APR_DECLARE(apr_status_t) apr_socket_opt
         break;
     case APR_IPV6_V6ONLY:
 #if APR_HAVE_IPV6
-        if (apr_os_level < APR_WIN_VISTA && 
+        if (apr_os_level < APR_WIN_VISTA &&
             sock->local_addr->family == AF_INET6) {
             /* apr_set_option() called at socket creation */
             if (on) {

Modified: apr/apr/trunk/passwd/apr_getpass.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/passwd/apr_getpass.c?rev=1905414&r1=1905413&r2=1905414&view=diff
==============================================================================
--- apr/apr/trunk/passwd/apr_getpass.c (original)
+++ apr/apr/trunk/passwd/apr_getpass.c Sun Nov 20 07:14:38 2022
@@ -112,20 +112,20 @@ static char *get_password(const char *pr
 /* WCE lacks console. So the getpass is unsuported
  * The only way is to use the GUI so the getpass should be implemented
  * on per-application basis.
- */ 
+ */
     static char password[128];
     int n = 0;
     int ch;
 
     fputs(prompt, stderr);
-    
+
     while ((ch = _getch()) != '\r') {
         if (ch == EOF) /* EOF */ {
             fputs("[EOF]\n", stderr);
             return NULL;
         }
         else if (ch == 0 || ch == 0xE0) {
-            /* FN Keys (0 or E0) are a sentinal for a FN code */ 
+            /* FN Keys (0 or E0) are a sentinal for a FN code */
             ch = (ch << 4) | _getch();
             /* Catch {DELETE}, {<--}, Num{DEL} and Num{<--} */
             if ((ch == 0xE53 || ch == 0xE4B || ch == 0x053 || ch == 0x04b) && n) {
@@ -162,7 +162,7 @@ static char *get_password(const char *pr
             fputc('\a', stderr);
         }
     }
- 
+
     fputc('\n', stderr);
     password[n] = '\0';
     return password;
@@ -194,7 +194,7 @@ static char *get_password(const char *pr
             n = 0;
         }
     }
- 
+
     password[n] = '\0';
     printf("\n");
     if (n > (MAX_STRING_LEN - 1)) {