~chrjae/redshift/trunk

Viewing all changes in revision 185.

  • Committer: Christian Jaeger
  • Date: 2011-09-25 23:24:30 UTC
  • Revision ID: git-v1:a781499ac656a52c453291c67fc0b67fad7cf6ea
set buffering on stdout and stderr to line-buffered

Previously stdout would be block buffered and stderr unbuffered when
writing to a non-terminal.

This code works on Debian with libc 2.11.2. The man page of setvbuf
mentions that NULL can be used to avoid affecting the used buffer, but
doesn't mention whether the size argument is then ignored; testing on
Debian has revealed that this code works as intended, but I don't know
whether that's standard.

expand all expand all

Show diffs side-by-side

added added

removed removed

Lines of Context: