httpd-apreq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joe Schaefer <joe+gm...@sunstarsys.com>
Subject Re: 2.03-dev-rc3 (was Re: 5.6.1 segfaults during perl tests)
Date Fri, 11 Jun 2004 14:36:35 GMT
Geoffrey Young <geoff@modperlcookbook.org> writes:

> well, this is what I tried, both with and without the cast in the
> assignment. 

Right- the cast shouldn't make a difference in the assignment, 
because C will do an arithmetic conversion (from apr_off_t to apr_size_t)
anyway.

> but I guess the reason it fails 

Wait- does the patch you submitted still fail to compile or complete
the tests?  If so, please provide more details.  If it works, but
you're wondering why it didn't without the patch, it's probably 
because C doesn't do any arithmetic conversion on the *contents* 
of the pointer argument, it just pretends the bit-patterns are 
identical for apr_size_t and apr_off_t.  Evidently that's not 
kosher on your box (casting a pointer just changes the *pointer's* 
type, not the pointer's *contents*).

> is because the apr_off_t is larger (which I didn't realize - I thought
> they were both ints).

It depends on your LARGEFILE setting, since off_t's are usually used
to represent the seek pointer of a file.  If you're not using
LARGEFILES, they may both be ints, in which case apr_size_t 
can represent larger numbers (being unsigned).


-- 
Joe Schaefer


Mime
View raw message