Re: space reserved for WAL record does not match what was written: panic on windows

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Andres Freund <andres(at)2ndquadrant(dot)com>
Cc: David Rowley <dgrowleyml(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: space reserved for WAL record does not match what was written: panic on windows
Date: 2013-10-07 17:25:17
Message-ID: CA+TgmoYr5anvMEZ0Vorp18hNpiw+-OSgkx0wXf4rYw_QvOGeUA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-www

On Fri, Oct 4, 2013 at 8:19 AM, Andres Freund <andres(at)2ndquadrant(dot)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

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Kevin Grittner 2013-10-07 17:26:47 drop-index-concurrently-1 on master fails at serializable
Previous Message Marc Cousin 2013-10-07 16:32:01 segfault with contrib lo

Browse pgsql-www by date

  From Date Subject
Next Message Andres Freund 2013-10-07 20:47:57 Re: space reserved for WAL record does not match what was written: panic on windows
Previous Message David Rowley 2013-10-04 13:26:02 Re: space reserved for WAL record does not match what was written: panic on windows