William A. Rowe, Jr. wrote:
Forwarding to the correct list.
Sorry, I missed that Apache 2.0 is devided into HTTPD and APR (and APR-UTIL)... Anyway, it is also HTTPD related patch/issue due to potential consequences in httpd-2.0 (size of request_rec struct shared between the core and external modules).
No objection here; but if patch is complete (?) then wtf are the extra two bits still doing here (no your patch Novy, but hanging on with the port to apr.) And if they will still exist, should we be setting those flags absolute, or |='ing that bit? (We don't appear to reset the other two bits in the same pass, though perhaps we always should have.)
Bill
Call to a memset is made for whole struct just before this assignment in apr_uri.c (two occurrences), so "=" has the same effect like "|=" here. If you think that it would be done by a different way, change it please.
My basic idea was to remove problematic bitfield from the struct and left it still extendable. I don't known if there is any reason to have other extra bits here at the moment - they probably came from Apache 1.3 project. BTW, I didn't find any reference to these DNS related variables (bits) in the sources (httpd-2.0, apr, apr-util), but maybe some 3rd party modules are using them...
"|=", "&=~" and "&" operations can be ordinarily used for setting, resetting and testing of individual bits, then.
Pavel
----- Original Message ----- From: "Pavel Novy" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Monday, November 19, 2001 8:46 AM
Subject: [PATCH] Apache 2.0 and NetWare - compatibility issue (second try)
Hi,
here are the corresponding patches to solve implementation/alignment issues with the bitfield used in a shared struct (apr_uri_t -> request_rec). These problems are occuring if compiling Apache 2.0 for NetWare (Apache 1.3 also) with various compilers (gcc, Watcom, CodeWarrior). Changes are designed for "apr-util/include/apr_uri.h" and "apr-util/uri/apr_uri.c" files. There are some other ways how it could be changed here, of course - we can use "unsigned long" to store the flags instead of "unsigned char" here (to alocate space for future use), define "is_initialized" separately etc. Size of a request_rec struct (defined in httpd-2.0/include/httpd.h) may be potentially affected by these changes on some other target platforms (not only on NetWare), so it's needed to test it on all platforms thoroughly...
Thanks, Pavel
