﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	severity	resolution	keywords	cc
508	psLogSetDestination is inconsistent	Paul Price	Paul Price	"Some parts of the SDRS state:
Specifying a \code{format} of \code{NULL} turns off logging (equivalent
to calling \code{psLogSetDestination(PS_LOG_TO_NONE)}, whereas if the
\code{format} is \code{""""}, then the format reverts to the default.

But the definition says:

bool psLogSetDestination(int fd);      
If the \code{fd} is 0, then the log is sent to standard output,
otherwise it is sent to the specified file descriptor.  A call to
\code{psLogSetDestination} automatically closes an open file
descriptor.

And the implementation has an enum, with PS_LOG_NONE = 0, which means that the
user thinks the logging is being turned on to stdout, but it's been disabled.

To fix this, I propose:

enum {
    PS_LOG_TO_NONE = 0,                  ///< turn off logging
    PS_LOG_TO_STDOUT = 1,                ///< log to system's stdout
    PS_LOG_TO_STDERR = 2,                ///< log to system's stderr
};

These values echo the file descriptor values for stdin, stdout and stderr,
repectively.  I would argue that this makes the most sense.

I will fix the SDRS, if there are no objections."	defect	closed	high		PSLib SDRS	unspecified	normal	fixed		robert.desonia@…
