Lines Matching refs:newfd
134 copy_content (Elf *elf, int newfd, off_t off, size_t n) in copy_content() argument
146 return write_retry (newfd, rawfile + off, n) != (ssize_t) n; in copy_content()
234 int newfd = mkstemp (tmpfname); in handle_file() local
235 if (unlikely (newfd == -1)) in handle_file()
244 if (unlikely (write_retry (newfd, ARMAG, SARMAG) != SARMAG)) in handle_file()
249 if (newfd != -1) in handle_file()
250 close (newfd); in handle_file()
265 && ((write_retry (newfd, symtab.symsoff, in handle_file()
268 || (write_retry (newfd, symtab.symsname, in handle_file()
274 && copy_content (arelf, newfd, SARMAG, index_off - SARMAG)) in handle_file()
275 || copy_content (arelf, newfd, rest_off, st.st_size - rest_off) in handle_file()
278 || fchmod (newfd, st.st_mode & ALLPERMS) != 0 in handle_file()
280 || (({asm ("" :: "r" (fchown (newfd, st.st_uid, st.st_gid))); }), in handle_file()
281 close (newfd) != 0) in handle_file()
282 || (newfd = -1, rename (tmpfname, fname) != 0)) in handle_file()