- Notifications
You must be signed in to change notification settings - Fork27
Commita315725
committed
Replace use of mktemp
This uses NamedTemporaryFile with delete=False to replace the oneuse of the deprecated mktemp function in smmap (reported in#41).This avoids the race condition inherent to mktemp, as the file isnamed and created together in a way that is effectively atomic.Because NamedTemporaryFile is not being used to automaticallydelete the file, it use and cleanup are unaffected by the change.1 parent7d6f97c commita315725
1 file changed
+4
-4
lines changedLines changed: 4 additions & 4 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
18 | 18 |
| |
19 | 19 |
| |
20 | 20 |
| |
21 |
| - | |
22 | 21 |
| |
23 | 22 |
| |
24 |
| - | |
25 |
| - | |
26 |
| - | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
27 | 27 |
| |
28 | 28 |
| |
29 | 29 |
| |
|
0 commit comments
Comments
(0)