Skip to content
Commit 0b15b140 authored by Dan Albert's avatar Dan Albert
Browse files

Fix error checking in get_temp_file_name().

Checking errno without first checking that the call failed means that
if some other call prior to mkstemp failed with EINVAL prior to this,
the assert would fire even if mkstemp succeeded. If something failed
with EEXIST, it would go in to an infinite loop.

Change-Id: I3f140a3e15fe08664a38a8c9a950c4ed547eb481
llvm-svn: 229035
parent 63bef0d1
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment