Don't use mktemp(), we are sure mkstemp() is available now
This commit is contained in:
parent
58fdb16e75
commit
23f6917b10
4
build.c
4
build.c
|
@ -112,11 +112,7 @@ static char * getTarSpec(const char *arg)
|
|||
specDir = rpmGetPath("%{_specdir}", NULL);
|
||||
tmpSpecFile = rpmGetPath("%{_specdir}/", "rpm-spec.XXXXXX", NULL);
|
||||
|
||||
#if defined(HAVE_MKSTEMP)
|
||||
(void) close(mkstemp(tmpSpecFile));
|
||||
#else
|
||||
(void) mktemp(tmpSpecFile);
|
||||
#endif
|
||||
|
||||
for (try = tryspec; *try != NULL; try++) {
|
||||
FILE *fp;
|
||||
|
|
|
@ -331,11 +331,7 @@ static int rpmReSign(rpmts ts, QVA_t qva, ARGV_const_t argv)
|
|||
/* Write the lead/signature of the output rpm */
|
||||
strcpy(tmprpm, rpm);
|
||||
strcat(tmprpm, ".XXXXXX");
|
||||
#if defined(HAVE_MKSTEMP)
|
||||
(void) close(mkstemp(tmprpm));
|
||||
#else
|
||||
(void) mktemp(tmprpm);
|
||||
#endif
|
||||
trpm = tmprpm;
|
||||
|
||||
if (manageFile(&ofd, trpm, O_WRONLY|O_CREAT|O_TRUNC))
|
||||
|
|
Loading…
Reference in New Issue