X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fdata%2Fmake-file.h;h=2e424fefdf8f4d8716617950c932d6bc2874b861;hb=40214686362e348692b4b6bd05ed5522189525c0;hp=31795bebe58db8d4b66d187c2ba9f3978369d7e2;hpb=cfbbebdd6b3085f4094c073e4ebd139ac1d37737;p=pspp diff --git a/src/data/make-file.h b/src/data/make-file.h index 31795bebe5..2e424fefdf 100644 --- a/src/data/make-file.h +++ b/src/data/make-file.h @@ -21,17 +21,7 @@ #include #include -/* Creates a temporary file and stores its name in *FILE_NAME and - a file descriptor for it in *FD. Returns success. Caller is - responsible for freeing *FILE_NAME. */ -int make_temp_file (int *fd, char **file_name); - - -/* Creates a temporary file and stores its name in *FILE_NAME and - a file stream for it in *FP. Returns success. Caller is - responsible for freeing *FILE_NAME. */ -int make_unique_file_stream (FILE **fp, char **file_name) ; - +struct file_handle; /* Prepares to atomically replace a (potentially) existing file by a new file, by creating a temporary file with the given @@ -49,7 +39,7 @@ int make_unique_file_stream (FILE **fp, char **file_name) ; The caller is responsible for closing *FP, but *TMP_NAME is owned by the callee. */ -struct replace_file *replace_file_start (const char *file_name, +struct replace_file *replace_file_start (const struct file_handle *fh, const char *mode, mode_t permissions, FILE **fp, char **tmp_name);