Re: Syslogger tries to write to /dev/null on Windows - Mailing list pgsql-bugs

From Magnus Hagander
Subject Re: Syslogger tries to write to /dev/null on Windows
Date
Msg-id p2m9837222c1004010419sa5a084bei9a79099563c7988c@mail.gmail.com
Whole thread Raw
In response to Syslogger tries to write to /dev/null on Windows  (Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>)
List pgsql-bugs
2010/4/1 Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>:
> NULL_DEV is defined in c.h as "/dev/null", which doesn't work on
> windows. We have a port-specific #define DEVNULL which does work, we
> should be using that.

Wow. Looking at the code around NULL_DEV, that actually looks like a
merge mistake from the old windows branch or something - it has a
comment stating that it should be different on NT, but it isn't...


> Peter Eisentraut inadvertently fixed this for 8.4:
>
> http://archives.postgresql.org/pgsql-committers/2008-12/msg00095.php
>
> by removing NULL_DEV and using always DEVNULL, but back-branches need
> that too. I'll leave NULL_DEV as it is just in case it's used by 3rd
> party modules, but change the two uses of it to use DEVNULL.

Sounds good to me.

--
 Magnus Hagander
 Me: http://www.hagander.net/
 Work: http://www.redpill-linpro.com/

pgsql-bugs by date:

Previous
From: Heikki Linnakangas
Date:
Subject: Syslogger tries to write to /dev/null on Windows
Next
From: "Jyothi"
Date:
Subject: BUG #5401: make: *** [pg_rman] Error 1