www-apache-bugdb mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From <ntv@cocacoliker.com> <...@cocacoliker.com>
Subject Re: config/7682: mod_unique_id requires the hostname of the server
Date Mon, 21 May 2001 06:40:01 GMT
The following reply was made to PR config/7682; it has been noted by GNATS.

From: <ntv@cocacoliker.com> <ntv@cocacoliker.com>
To: apache-bugdb@apache.org,trawick@apache.org
Cc: apbugs@Apache.Org
Subject: =?iso-8859-1?Q?Re: config/7682: mod=5Funique=5Fid requires the hostname of the server?=
Date: Mon, 21 May 2001 08:33:12 +0200

 Hi
 
 I haven't got the /src/ directory (i dont have the source i guess). 
 And frankly i dont know how to apply this patch.
 I'm sure i can do this if i get further directions and/or files.
 
 
 -- Original message --
 
 Synopsis: mod_unique_id requires the hostname of the server
 
 State-Changed-From-To: open-feedback
 State-Changed-By: trawick
 State-Changed-When: Fri May 18 07:21:25 PDT 2001
 State-Changed-Why:
 I would guess that the problem is that BEOS logic is needed
 in mod_unique_id.c to handle the return code from 
 gethostname().  Unfortunately, certain (all?) levels of 
 BeOS trigger a gethostname() failure differently than 
 all other platforms on which Apache is supported.
 
 Please try this patch to mod_unique_id:
 
 Index: src/modules/standard/mod_unique_id.c
 ===================================================================
 RCS file: /home/cvs/apache-1.3/src/modules/standard/mod_unique_id.c,v
 retrieving revision 1.23
 diff -u -r1.23 mod_unique_id.c
 --- src/modules/standard/mod_unique_id.c	2001/01/15 17:05:51	1.23
 +++ src/modules/standard/mod_unique_id.c	2001/05/18 14:19:15
 @@ -193,7 +193,11 @@
       * of the addresses from the main_server, since those aren't as likely 
 to
       * be unique as the physical address of the machine
       */
 +#ifdef BEOS /* BeOS returns zero as an error for gethostname */
 +    if (gethostname(str, sizeof(str) - 1) == 0) {
 +#else
      if (gethostname(str, sizeof(str) - 1) != 0) {
 +#endif
          ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_ALERT, s,
  		     "gethostname: mod_unique_id requires the "
  		     "hostname of the server");
 
 Please let me know if you are unable to test the patch.
 Maybe I can find somebody to do that.
 

Mime
View raw message