[PATCH] exa: Accept scratch pixmaps with offscreen memory as such.
Maarten Maathuis
madman2003 at gmail.com
Thu Mar 19 11:48:07 PDT 2009
>> >> + if ((CARD8 *)pPixData >= pExaScr->info->memoryBase &&
>> >> + (CARD8 *)pPixData < (pExaScr->info->memoryBase + pExaScr->info->memorySize)) {
>> >
>> > (pExaScr->info->memoryBase + pExaScr->info->memorySize) could wrap
>> > around to 0, in which case the latter check would always fail.
>>
>> I don't see how that failure is bad (considering it won't wrap for the
>> cases that are offscreen).
>
> You don't seem to understand: pPixData < 0 is false for any value of
> pPixData.
>
If it folds, then it means that (pExaScr->info->memoryBase +
pExaScr->info->memorySize) is outside the range of a uint32_t or
uint64_t, how much sense would a mapped memory range make if it didn't
fit into address space?
More information about the xorg-devel
mailing list