The Samba-Bugzilla – Attachment 14325 Details for
Bug 13533
Unlink in have_secure_mkstemp causes build failure
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch to move unlink to only be run before exit
mkstemp-patch.txt (text/plain), 1.48 KB, created by
ajburley
on 2018-07-16 18:14:30 UTC
(
hide
)
Description:
Patch to move unlink to only be run before exit
Filename:
MIME Type:
Creator:
ajburley
Created:
2018-07-16 18:14:30 UTC
Size:
1.48 KB
patch
obsolete
>diff -Naur talloc-2.1.14/lib/replace/wscript talloc-2.1.14-mkstempfix/lib/replace/wscript >--- talloc-2.1.14/lib/replace/wscript 2018-07-12 05:51:30.000000000 +0000 >+++ talloc-2.1.14-mkstempfix/lib/replace/wscript 2018-07-16 17:53:44.853417533 +0000 >@@ -680,16 +680,28 @@ > exit(1); > } > if (fd2 == -1) exit(1); >- unlink(tpl); >- unlink(tpl2); >- if (fstat(fd, &st) != 0) exit(1); >- if ((st.st_mode & 0777) != 0600) exit(1); >+ if (fstat(fd, &st) != 0) { >+ unlink(tpl); >+ unlink(tpl2); >+ exit(1); >+ } >+ if ((st.st_mode & 0777) != 0600) { >+ unlink(tpl); >+ unlink(tpl2); >+ exit(1); >+ } > if (strcmp(tpl, "/tmp/test.XXXXXX") == 0) { >+ unlink(tpl); >+ unlink(tpl2); > exit(1); > } > if (strcmp(tpl, tpl2) == 0) { >+ unlink(tpl); >+ unlink(tpl2); > exit(1); > } >+ unlink(tpl); >+ unlink(tpl2); > exit(0); > ''', > define='HAVE_SECURE_MKSTEMP',
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 13533
: 14325