From: Rich Felker Date: Fri, 15 Apr 2011 01:43:49 +0000 (-0400) Subject: make tmpfile slightly more efficient (use unlink syscall instead of remove) X-Git-Tag: v0.7.9~48 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=b172dc8b58a5db37d61cb4718cd42628126710f1;p=oweals%2Fmusl.git make tmpfile slightly more efficient (use unlink syscall instead of remove) --- diff --git a/src/stdio/tmpfile.c b/src/stdio/tmpfile.c index a6b72236..18c232f7 100644 --- a/src/stdio/tmpfile.c +++ b/src/stdio/tmpfile.c @@ -17,7 +17,7 @@ FILE *tmpfile(void) fd = syscall(SYS_open, s, O_RDWR|O_CREAT|O_EXCL|O_LARGEFILE, 0600); if (fd >= 0) { f = __fdopen(fd, "w+"); - remove(s); + syscall(SYS_unlink, s); return f; } }