From: René Scharfe Date: Tue, 14 Jul 2026 17:59:55 +0000 (+0200) Subject: tempfile: stop using the_repository X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=75e05f6bc3b3e04301d25327f54b2c9998471c1d;p=thirdparty%2Fgit.git tempfile: stop using the_repository Remove the compatibility wrappers create_tempfile_mode() and create_tempfile() that have become unused. Signed-off-by: René Scharfe Signed-off-by: Junio C Hamano --- diff --git a/tempfile.c b/tempfile.c index 3132eb4371..dc9ca4e645 100644 --- a/tempfile.c +++ b/tempfile.c @@ -42,8 +42,6 @@ * file created by its parent. */ -#define USE_THE_REPOSITORY_VARIABLE - #include "git-compat-util.h" #include "abspath.h" #include "path.h" @@ -134,11 +132,6 @@ static void deactivate_tempfile(struct tempfile *tempfile) } /* Make sure errno contains a meaningful value on error */ -struct tempfile *create_tempfile_mode(const char *path, int mode) -{ - return repo_create_tempfile_mode(the_repository, path, mode); -} - struct tempfile *repo_create_tempfile_mode(struct repository *r, const char *path, int mode) { diff --git a/tempfile.h b/tempfile.h index 2d17e4dad3..f571f3c609 100644 --- a/tempfile.h +++ b/tempfile.h @@ -94,16 +94,9 @@ struct tempfile { * `core.sharedRepository`, so it is not guaranteed to have the given * mode. */ -struct tempfile *create_tempfile_mode(const char *path, int mode); - struct tempfile *repo_create_tempfile_mode(struct repository *r, const char *path, int mode); -static inline struct tempfile *create_tempfile(const char *path) -{ - return create_tempfile_mode(path, 0666); -} - static inline struct tempfile *repo_create_tempfile(struct repository *r, const char *path) {