Lines Matching refs:a_file
69 char *a_file);
70 static int create_path(int a_ctrl, char *a_file);
233 create_path(int a_ctrl, char *a_file) in create_path() argument
238 for (pt = a_file; *pt; pt++) { in create_path()
241 if ((*pt != '/') || (pt == a_file)) { in create_path()
251 if (access(a_file, F_OK) == 0) { in create_path()
258 if (mkdir(a_file, 0755)) { in create_path()
259 progerr(ERR_MAKE_DIR, a_file, errno, strerror(errno)); in create_path()
267 echo(MSG_IMPDIR, a_file); in create_path()
296 write_file(char **r_linknam, int a_ctrl, mode_t a_mode, char *a_file) in write_file() argument
304 echoDebug(DBG_WRITEFILE_ENTRY, a_ctrl, a_mode, a_file); in write_file()
315 if (access(a_file, F_OK) == 0) { in write_file()
322 if (!RELATIVE(a_file)) { in write_file()
324 "%sXXXXXX", a_file); in write_file()
326 progerr(ERR_CREATE_PATH_2, a_file, "XXXXXX"); in write_file()
329 logerr(WRN_RELATIVE, a_file); in write_file()
331 "./%sXXXXXX", a_file); in write_file()
333 progerr(ERR_CREATE_PATH_3, "./", a_file, in write_file()
364 fd = open(a_file, O_WRONLY | O_CREAT | O_TRUNC, a_mode); in write_file()
366 if (create_path(a_ctrl, a_file) == 0) { in write_file()
367 fd = open(a_file, O_WRONLY | O_CREAT | O_TRUNC, a_mode); in write_file()
372 progerr(ERR_OPEN_WRITE, a_file, errno, strerror(errno)); in write_file()