|
From: Josef W. <Jos...@gm...> - 2005-05-01 20:02:55
|
On Saturday 30 April 2005 01:03, Josef Weidendorfer wrote:
> But in the debug output which you sent me in private I saw that the output
> is written to file descriptor 0 in the end. I have to check if there is a
> bug somewhere in my code, as 0 is not the usual case. Stay tuned...
OK. This bug should be fixed by the following 1-liner.
--- callgrind/src/dump.c 2 Apr 2005 02:13:50 -0000 1.8
+++ callgrind/src/dump.c 1 May 2005 19:57:38 -0000
@@ -150,7 +150,7 @@ static Int fwrite_fd = -1;
static __inline__
void fwrite_flush()
{
- if ((fwrite_fd>0) && (fwrite_pos>0))
+ if ((fwrite_fd>=0) && (fwrite_pos>0))
VG_(write)(fwrite_fd, (void*)fwrite_buf, fwrite_pos);
fwrite_pos = 0;
}
Can you confirm this?
Josef
|