Bug 3202 - stderr is read-only on Solaris
Summary: stderr is read-only on Solaris
Status: RESOLVED FIXED
Alias: None
Product: cairo
Classification: Unclassified
Component: general (show other bugs)
Version: 0.9.3
Hardware: SPARC Solaris
: high normal
Assignee: Carl Worth
QA Contact: cairo-bugs mailing list
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-05-04 01:38 UTC by Damien Carbery
Modified: 2005-08-22 00:14 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
Remove assignment of stderr in test/cairo-test.c (1.09 KB, patch)
2005-05-04 01:39 UTC, Damien Carbery
Details | Splinter Review

Description Damien Carbery 2005-05-04 01:38:44 UTC
In the cairo_test_real() function in test/cairo-test.c, the current value of
'stderr' is saved and restored later. 'stderr' is read-only on Solaris.

Compiler error:
"cairo-test.c", line 355: left operand must be modifiable lvalue: op "="
"cairo-test.c", line 372: left operand must be modifiable lvalue: op "="

I don't understand why it is saved. Attached patch removes the save/restore code
and uses 'Stderr' instead of 'stderr' for the file handle.
Comment 1 Damien Carbery 2005-05-04 01:39:21 UTC
Created attachment 2616 [details] [review]
Remove assignment of stderr in test/cairo-test.c
Comment 2 Carl Worth 2005-05-04 06:32:54 UTC
That's annoying, (though I did wonder for a moment if writing to stderr
was kosher or not).

The goal here was to easily get individual test output to log files rather
than spewing to the tty. One way to fix it in the face of read-only stderr
is to add something like a cairo_test_log function and change all occurrences
of fprintf(stder, ...) in cairo/test/*.c to call cairo_test_log instead.
Comment 3 Carl Worth 2005-05-10 20:26:39 UTC
I've now committed a change that eliminates the write to stderr and
implements cairo_test_log as suggested.
Comment 4 Carl Worth 2005-08-22 17:14:26 UTC
Move bugs against "cvs" version to "0.9.3" so we can remove the "cvs" version.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.