Project

General

Profile

Actions

Bug #8816

closed

Tempfile.new may return the same name for parallel calls

Added by 375gnu (Hleb Valoshka) over 11 years ago. Updated over 11 years ago.

Status:
Third Party's Issue
Assignee:
-
Target version:
-
ruby -v:
ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-linux]
[ruby-core:56795]

Description

Two simultaneous call to Tempfile.new may return the same name. This may lead
to race conditions.

There some examples of such races (unix socket can't be unlinked because it was
unlinked by another test case):

https://buildd.debian.org/status/fetch.php?pkg=ruby-kgio&arch=ia64&ver=2.8.0-1&stamp=1376819434
https://buildd.debian.org/status/fetch.php?pkg=ruby-kgio&arch=kfreebsd-i386&ver=2.8.0-1&stamp=1376820662

Actions

Also available in: Atom PDF

Like0
Like0Like0Like0