Re: space reserved for WAL record does not match what was written: panic on windows - Mailing list pgsql-hackers

From Robert Haas
Subject Re: space reserved for WAL record does not match what was written: panic on windows
Date
Msg-id CA+TgmoYr5anvMEZ0Vorp18hNpiw+-OSgkx0wXf4rYw_QvOGeUA@mail.gmail.com
Whole thread Raw
In response to Re: space reserved for WAL record does not match what was written: panic on windows  (Andres Freund <andres@2ndquadrant.com>)
Responses Re: space reserved for WAL record does not match what was written: panic on windows  (Andres Freund <andres@2ndquadrant.com>)
List pgsql-hackers
On Fri, Oct 4, 2013 at 8:19 AM, Andres Freund <andres@2ndquadrant.com> wrote:
> Could it be that MAXALIGN/TYPEALIGN doesn't really work for values
> bigger than 32bit?
>
> #define MAXALIGN(LEN)                   TYPEALIGN(MAXIMUM_ALIGNOF, (LEN))
> #define TYPEALIGN(ALIGNVAL,LEN)  \
>         (((intptr_t) (LEN) + ((ALIGNVAL) - 1)) & ~((intptr_t) ((ALIGNVAL) - 1)))

Isn't the problem, more specifically, that it doesn't work for values
larger than an intptr_t?

And does that indicate that intptr_t is the wrong type to be using here?

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company



pgsql-hackers by date:

Previous
From: Marc Cousin
Date:
Subject: segfault with contrib lo
Next
From: Robert Haas
Date:
Subject: Re: mvcc catalo gsnapshots and TopTransactionContext