Commit b8b28a72 authored by Matthias Clasen's avatar Matthias Clasen Committed by Matthias Clasen
Browse files

Don't repeat a failed fclose() call, since that invokes undefined

2006-04-26  Matthias Clasen  <mclasen@redhat.com>

	* glib/grand.c (g_rand_new): Don't repeat a failed fclose()
	call, since that invokes undefined behaviour.  (Coverity)
parent d4ac791e
2006-04-26 Matthias Clasen <mclasen@redhat.com>
* glib/grand.c (g_rand_new): Don't repeat a failed fclose()
call, since that invokes undefined behaviour. (Coverity)
2006-04-25 Matthias Clasen <mclasen@redhat.com>
* glib/gbookmarkfile.c (is_element_full): Avoid a possible
......
2006-04-26 Matthias Clasen <mclasen@redhat.com>
* glib/grand.c (g_rand_new): Don't repeat a failed fclose()
call, since that invokes undefined behaviour. (Coverity)
2006-04-25 Matthias Clasen <mclasen@redhat.com>
* glib/gbookmarkfile.c (is_element_full): Avoid a possible
......
......@@ -191,12 +191,7 @@ g_rand_new (void)
if (r != 1)
dev_urandom_exists = FALSE;
do
{
errno = 0;
fclose (dev_urandom);
}
while G_UNLIKELY (errno == EINTR);
fclose (dev_urandom);
}
else
dev_urandom_exists = FALSE;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment