Kaydet (Commit) 3ee933f1 authored tarafından Victor Stinner's avatar Victor Stinner

Issue #27776: dev_urandom(raise=0) now closes the file descriptor on error

üst 6974cf2c
......@@ -331,6 +331,7 @@ dev_urandom(char *buffer, Py_ssize_t size, int raise)
if (n <= 0) {
/* stop on error or if read(size) returned 0 */
close(fd);
return -1;
}
......
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