Lines Matching defs:state_file
106 if (!u->state_file)
109 r = mkdir_parents(u->state_file, 0755);
112 u->state_file);
114 r = fopen_temporary(u->state_file, &f, &temp_path);
117 u->state_file);
128 if (!u->state_file || !u->last_cursor)
131 r = fopen_temporary(u->state_file, &f, &temp_path);
144 if (rename(temp_path, u->state_file) < 0) {
155 (void) unlink(u->state_file);
157 return log_error_errno(r, "Failed to save state %s: %m", u->state_file);
163 if (!u->state_file)
166 r = parse_env_file(u->state_file, NEWLINE,
171 log_debug("State file %s is not present.", u->state_file);
174 u->state_file);
425 static int setup_uploader(Uploader *u, const char *url, const char *state_file) {
456 u->state_file = state_file;