Commit 78aa4a3c authored by Eric Engestrom's avatar Eric Engestrom 💤
Browse files

mesa: stop trying new filenames if the filename existing is not the issue


Signed-off-by: Eric Engestrom's avatarEric Engestrom <eric.engestrom@intel.com>
Reviewed-by: Kristian H. Kristensen's avatarKristian H. Kristensen <hoegsberg@google.com>
Reviewed-by: default avatarMarek Olšák <marek.olsak@amd.com>
parent d02d2b62
Pipeline #45540 passed with stages
in 8 minutes and 41 seconds
......@@ -37,6 +37,7 @@
*/
#include <errno.h>
#include <stdbool.h>
#include <c99_alloca.h>
#include "main/glheader.h"
......@@ -1255,6 +1256,11 @@ link_program(struct gl_context *ctx, struct gl_shader_program *shProg,
file = os_file_create_unique(filename, 0644);
if (file)
break;
/* If we are failing for another reason than "this filename already
* exists", we are likely to fail again with another filename, so
* let's just give up */
if (errno != EEXIST)
break;
ralloc_free(filename);
}
if (file) {
......
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